KEY
This commit is contained in:
commit
60bc8223b0
1 file changed
+6
-7
+6
-7
@@ -4,6 +4,7 @@ using System.Collections.Generic;
|
|||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
|
using System.Threading;
|
||||||
using System.Windows;
|
using System.Windows;
|
||||||
using System.Windows.Controls;
|
using System.Windows.Controls;
|
||||||
using System.Windows.Data;
|
using System.Windows.Data;
|
||||||
@@ -105,11 +106,14 @@ namespace SUNLIGHT_CDKEY
|
|||||||
|
|
||||||
private void Button_Click(object sender, RoutedEventArgs e)
|
private void Button_Click(object sender, RoutedEventArgs e)
|
||||||
{
|
{
|
||||||
|
|
||||||
string a;
|
string a;
|
||||||
string b, my, mm, md;
|
string b, my, mm, md;
|
||||||
|
|
||||||
if (sn_id.Text == "") return;
|
if (sn_id.Text.Length <6)
|
||||||
|
{
|
||||||
|
sn_id.BorderBrush = new SolidColorBrush(System.Windows.Media.Color.FromArgb(255, 255,0, 0));
|
||||||
|
return;
|
||||||
|
}else sn_id.BorderBrush = new SolidColorBrush(System.Windows.Media.Color.FromArgb(255, 255, 255, 255));
|
||||||
|
|
||||||
a = sn_id.Text.Substring(0, 6);
|
a = sn_id.Text.Substring(0, 6);
|
||||||
|
|
||||||
@@ -118,11 +122,6 @@ namespace SUNLIGHT_CDKEY
|
|||||||
md = Convert.ToString(Convert.ToInt32(255-d), 16).ToUpper();
|
md = Convert.ToString(Convert.ToInt32(255-d), 16).ToUpper();
|
||||||
b=my+mm+md;
|
b=my+mm+md;
|
||||||
|
|
||||||
|
|
||||||
a= sn_id.Text.Substring(0, 6);
|
|
||||||
b=(2255-y).ToString()+(255-m).ToString()+(255-d).ToString();
|
|
||||||
|
|
||||||
|
|
||||||
cdk.Text = a + b + CRCcheck16.ToCRC16(CRCcheck16.StringToHexByte(b), true);
|
cdk.Text = a + b + CRCcheck16.ToCRC16(CRCcheck16.StringToHexByte(b), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user