A piece of code that obtains the network card address can be used for software licenses.
Author:Eve Cole
Update Time:2009-06-30 15:46:36
ManagementClass mcMAC = new ManagementClass("Win32_NetworkAdapterConfiguration");
ManagementObjectCollection mocMAC = mcMAC.GetInstances();
foreach(ManagementObject m in mocMAC)
{
if((bool)m["IPEnabled"])
{
return m["MacAddress"].ToString();
}
}