Пример #1
0
 private static bool ConnectToLicenseServer(ref string license, string product, string productversion, string productbuild, string productSerial, string ipAddress, string macAddress, string allMacAddress, string hdSerial, string osVersion)
 {
     // send request to License server
     try
     {
         var eltService = new EltekLicenseServiceClient();
         // license = eltService.GetLicense(product, productversion, productbuild, CUSTOMER, productSerial, Environment.UserName, Environment.MachineName, ipAddress, macAddress, hdSerial, osVersion);
         license = eltService.GetLicenseVer2Async(product, productversion, productbuild, CUSTOMER, productSerial, Environment.UserName, Environment.MachineName, ipAddress, macAddress, allMacAddress, hdSerial, osVersion).Result;
         return(true);
     }
     catch (Exception)
     {
         license = string.Empty;
         return(false);
     }
 }