标签:+= padleft rap stat res val default VID []
public static string MD5String(string value)
{
System.Security.Cryptography.MD5 md5 = new System.Security.Cryptography.MD5CryptoServiceProvider();
byte[] data = Encoding.Default.GetBytes(value);
byte[] md5Data = md5.ComputeHash(data);
md5.Clear();
string result = "";
for (int i = 0; i < md5Data.Length; i++)
{
result += md5Data[i].ToString("x").PadLeft(2, ‘0‘);
}
return result;
}
标签:+= padleft rap stat res val default VID []
原文地址:https://www.cnblogs.com/AllStarGIS/p/9432996.html