16进制格式化

a.ToString("x")可以把10变成a  
string.Format("{0:xxxx}", a)可以把10变成000a 

原文地址:https://www.cnblogs.com/z45281625/p/9525174.html