How to verify activated license key after it is released from Server
We have developed a WPF Desktop application (language is C#) and are using QLM for licensing. It need to support Offline activation also.
My client has provided me 30 keys with each one having 5 Number of licenses means same key can be activated on 5 different systems.
The flow goes like this -
- 1st time User activates his System by passing the license key in application.
- Application verifies the key online using this function - ActivateLicense (string webServiceUrl, string activationKey, string computerID, string computerName, string qlmVersion, string userData1, out string response). https://support.soraco.co/hc/en-us/articles/207295216-QlmLicense-ActivateLicense
- If SUCCESS - We save ComputerKey in Registry Entry (RegEdit HKLM).
- During all next run we do check Registry entries - if we found this entry from #3 - we do not go Online again to verify this license.
- This is
Problem: If any activated Key gets Released from QLM Server. How do we check this application side?
Regards,
Kanak
-
Official comment
There are a couple ways:
1. Check if the license is activated on the server using IsLicenseKeyActivated
2. Check if QLM determines that the current system is illegal (meaning released on the server but activated on the client) using IsIllegalComputer
Assuming you are using the LicenseValidator class, all you need to do is set the variable checkIfComputerIsRegistered to true to enable a call to IsIllegalComputer.
Regards
John
Comment actions -
Hi,
Thanks for the help provided, we tried the 1st approach provided above, and it works fine with Activation type license keys.
But, we have a query regarding the Demo type license keys, as the above method, IsLicenseKeyActivated returns false for a valid/activated Demo type key. Is there any other approach we need to follow for Demo type license keys.
Problem 1: We are not able to track Demo type license keys in QLM license portal. Where can we find these type of keys?
Problem 2: If any activated Demo Key gets Released from QLM Server. How do we check this application side?
Regards,
Kanak
-
Hi Kanak
There are 2 types of trial keys:
1- a trial key that is not tracked by the server and can be distributed (the same key) to all your customers
2- a trial key that is tracked by the server and each customer requires a different key. This is the recommended type.
I assume you are using type 1 above but based on your description, you'd like to use type 2.
Did I understand you correctly?
Regards
John
Please sign in to leave a comment.
Comments
3 comments