using System.Security.Cryptography;
public static void Main()
string HASHTHIS = "Password";
Console.WriteLine("PasswordHash : " + ConvertStringToMD5(HASHTHIS));
public static string ConvertStringToMD5(string ClearText) {
byte[] ByteData = Encoding.ASCII.GetBytes(ClearText);
byte[] HashData = oMd5.ComputeHash(ByteData);
StringBuilder oSb = new StringBuilder();
for (int x = 0; x < HashData.Length; x++)
oSb.Append(HashData[x].ToString("x2"));