g_ramzi
November 4th, 2008, 12:26
how to make a keygen for this?
the "strkey" must be like this :: 11111111-1111111-111111111-111111111
public static void SetLicence (string strKey)
{
string str = "";
string str2 = "";
string str3 = "";
string str4 = "";
if ((strKey != ""
&& (strKey.Length == 35))
{
StringBuilder builder = new StringBuilder();
for (int i = 0; i < strKey.Length; i++)
{
if ((strKey[I] > 'F') && (strKey[I] < '['))
{
builder.Append('0');
}
else
{
builder.Append(strKey[I]);
}
}
strKey = builder.ToString();
str = strKey.Substring(0, 8);
strKey = strKey.Replace(str + "-", ""
;
str2 = strKey.Substring(0, 8);
strKey = strKey.Replace(str2 + "-", ""
;
str3 = strKey.Substring(0, 8);
strKey = strKey.Replace(str3 + "-", ""
;
str4 = strKey;
long num2 = 0L;
num2 += Convert.ToInt32(str.Substring(0, 3), 16);
num2 += Convert.ToInt32(str2.Substring(0, 3), 16);
num2 += Convert.ToInt32(str3.Substring(0, 3), 16);
if (num2 == Convert.ToInt32(str4, 16))
{
FileVersionInfo versionInfo = FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location);
string str5 = Convert.ToInt32(str.Substring(0, 6), 16).ToString();
if ((versionInfo.FileMajorPart.ToString("0"
+ versionInfo.FileMinorPart.ToString("00"
) == str5.Substring(0, 3))
{
string code = GetCode();
long num3 = 0L;
for (int j = 0; j < code.Substring(6).Length; j++)
{
num3 += (long) code.Substring(6)[j];
}
if (Convert.ToInt32(str2, 16) == ((num3 * 999) % 0x7fffffffL))
{
MessageBox.Show("Good Work!!!!"
;
}
}
}
}
if (menmLicenseType == LicenseType.Demo)
{
MessageBox.Show("Try again!!!!"
;
}
}
//// And Thanks a lot!!!!
the "strkey" must be like this :: 11111111-1111111-111111111-111111111
public static void SetLicence (string strKey)
{
string str = "";
string str2 = "";
string str3 = "";
string str4 = "";
if ((strKey != ""

{
StringBuilder builder = new StringBuilder();
for (int i = 0; i < strKey.Length; i++)
{
if ((strKey[I] > 'F') && (strKey[I] < '['))
{
builder.Append('0');
}
else
{
builder.Append(strKey[I]);
}
}
strKey = builder.ToString();
str = strKey.Substring(0, 8);
strKey = strKey.Replace(str + "-", ""

str2 = strKey.Substring(0, 8);
strKey = strKey.Replace(str2 + "-", ""

str3 = strKey.Substring(0, 8);
strKey = strKey.Replace(str3 + "-", ""

str4 = strKey;
long num2 = 0L;
num2 += Convert.ToInt32(str.Substring(0, 3), 16);
num2 += Convert.ToInt32(str2.Substring(0, 3), 16);
num2 += Convert.ToInt32(str3.Substring(0, 3), 16);
if (num2 == Convert.ToInt32(str4, 16))
{
FileVersionInfo versionInfo = FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location);
string str5 = Convert.ToInt32(str.Substring(0, 6), 16).ToString();
if ((versionInfo.FileMajorPart.ToString("0"


{
string code = GetCode();
long num3 = 0L;
for (int j = 0; j < code.Substring(6).Length; j++)
{
num3 += (long) code.Substring(6)[j];
}
if (Convert.ToInt32(str2, 16) == ((num3 * 999) % 0x7fffffffL))
{
MessageBox.Show("Good Work!!!!"

}
}
}
}
if (menmLicenseType == LicenseType.Demo)
{
MessageBox.Show("Try again!!!!"

}
}
//// And Thanks a lot!!!!