It's a easy tutorial of how do a simple and useful "system of key" to insert on your trainer.
First add the following import's.
So after add the function that will generate the key for each computer.
Now the "check function", you can add it on a button, checkbox, what you think better.
ManagementObjectCollection mbsList = null; // ManagementObjectCollection is referenced from the .:Ref folder ->
ManagementObjectSearcher mbs = new ManagementObjectSearcher("Select * From Win32_processor");
mbsList = mbs.Get();
string id = "";
foreach (ManagementObject mo in mbsList)
SerialID = mo["ProcessorID"].ToString();//key done
textBox1.Text = (SerialID);//key will be loaded on a textbox
string GrabCPUID = string.Empty;
WebClient webClient = new WebClient();//referenced by using System.Net;
string Key = null;
Key = webClient.DownloadString("http://example.com/example.txt");//there you define the host with .txt file that have the confirmed id's
// If the HWID is on .txt file will return this
// If the HWID isn't on the .txt will return this.
// If not connected to the internet or can't connect with the site of .txt file will return this
MessageBox.Show("Unable To Retrieve HWID");