private Guid CalculateGUID(object m)
{
ASCIIEncoding enc = new ASCIIEncoding();
string code = m.GetHashCode( ).ToString();
string key;
if (code.Length < 16)
key = code + new string( '*', 16 - code.Length );
else if (code.Length == 16)
{
key = code;
}
else
{
key = code.Substring( 0, 16 );
}
return new Guid(enc.GetBytes(key)) ;
}
1 comment:
Great Article
IEEE Projects for Engineering Students
Final Year Projects for CSE
Post a Comment