Online Activation using the QLM License Wizard Standalone Application

QLM provides a standalone application (QlmLicenseWizard.exe) that you can invoke from your application to simplify the process of online activation. When using QlmLicenseWizard.exe, there is almost no need to write any code to implement online activation. This method is ideal for non .NET applications that cannot use the QLM .NET User Control. Samples are provided for C++, MS-Access, Excel and others.

The QLM License Wizard allows your users to:

  • View the status of their license.

  • View the Check for Updates information and launch the installation of an update.

  • Activate a license online.

  • Activate a license offline (manual activation and activation via a QR Code).

  • Deactivate a license.

  • Display a User Registration page that can automatically generate a trial license.

  • Display an EULA page.

  • Display a Privacy Policy page.

  • and much more

The QlmLicenseWizard.exe can be used on any Windows 7 and higher system and requires that Microsoft .NET 4.62 or later be installed on the end-users system.

To use the QlmLicenseWizard.exe application:

  • From the QLM Console, create a product.

  • Go to the Protect your application tab and follow the instructions in the wizard.

  • Modify your application as follows:

    • When your application is launched, call the ValidateLicenseAtStartup function. This function is generated by the Protect your application wizard in the LicenseValidator class.

    • If the ValidateLicenseAtStartup function returns false, launch the QlmLicenseWizard.exe with the /settings argument.

    • When the QlmLicenseWizard.exe process exits, call ValidateLicenseAtStartup again to ensure that the license is valid.

Once the user has activated his license from the QlmLicenseWizard process, the license key is automatically stored in a hidden location on the end-user system.

Example

LicenseValidator lv = new LicenseValidator ();
if (lv.ValidateLicenseAtStartup(computerID, ref needsActivation, ref returnMsg) == false)
{
    // Launch the QlmLicenseWizard.exe process.
   string settingsFiles = "Demo 1.0.lw.xml"; // you must specify the full path to the settings file
   string args = String.Format("/settings \"{0}\"", settingsFile);

    lv.QlmLicenseObject.LaunchProcess(@"C:\Program Files\Soraco\QuickLicenseMgr\QlmLicenseWizard.exe", args, true, true);
    if (lv.ValidateLicenseAtStartup(computerID, ref needsActivation, ref returnMsg) == false)
    {
        // Exit the application
    }
}

The command-line arguments of QlmLicenseWizard.exe are:

Argument

Description

/settings "<full path to settings file>"

Path to the settings file generated by the Protect your application wizard (enclose the full path in double-quotes). This argument is required.

/uiSettings

Path to the UI settings file generated by the Protect your application. Not required as of QLM v9.

/computerID <computer identifier>

Optional argument. The unique identifier of the current system. If not argument is provided, the computerID is dynamically computed based on the QlmLicenseBinding property in the XML settings file. If your license binding is configured to be User Defined, this argument is required.

/activationKey <activation key>

Optional argument. By default, the activation key is automatically retrieved from the location associated with your products by calling the ReadKeys API. To override this behaviour, you can specify the activationKey on the command line.

/computerKey <computer key>

Optional argument. By default, the computer key is automatically retrieved from the location associated with your products by calling the ReadKeys API. To override this behaviour, you can specify the computerKey on the command line.

/floating_master

Optional argument. Displays the floating license page when activating the master node.

/floating_node

Optional argument. Displays the floating license page when activating a client node.

/appversion <version>

Optional argument. Sets the version of the application that's launching the wizard. This version is used in the Check for Updates feature.

/showur <0 | 1>

Optional argument. Displays the User Registration page.

/showprivacy <0 | 1>

Optional argument. Displays the Privacy Policy page only.

/locale <country_code>

Optional argument. Examples of country codes: fr, en, de, es, it, jp, etc.

/simulateDate

Optional argument. Simulates a date for testing purposes. The expected format of the date is: yyyy-MM-dd

/simulateNoConnectivity

Optional argument. Simulates no internet connectivity.

/topmost

Optional argument. Displays the wizard on top of all other windows

/left <x>

Optional argument. Left position of the wizard.

/top <y>

Optional argument. Top position of the wizard.

Upon exiting, the QlmLicenseWizard.exe process returns the following exit codes:

Exit Code

Description

0

The license is valid

1

The license is not valid

2

The license has expired

3

Usage error in the command line, typically indicating some missing or invalid arguments

4

The user cancelled the wizard

5

The user downloaded an update and launched the setup.

10

The deactivation of the license was successful. QLM v9 and later.

11

Deactivation of the license failed. QLM v9 and later.

12

The user did not consent to the privacy policy.

14

The floating database registration succeeded (as of v11.0.18144.1)

15

The floating database registration failed (as of v11.0.18144.1)

Last updated