Windows Installer, Java Installer, Freeware Installer
Home|Contact|Site Map|TOC|Search
Download  Features   Java  Licensing  Purchase  Testimonials  Support  Forums

Updater License Check

License check

You can set up the updater to check the license of the user that tries to call the autoupdate function. For this you must do two things:

  • when you check for updates (using the /checknow or /silent options) add an extra parameter for the license. This will represent a registry value containing the license. The registry value can be usually of string (REG_SZ) type. Any other type (REG_DWORD, REG_BINARY etc.) will be converted to a hexedecimal string. The registry path representation is using the same rules as the ones described for the updates configuration file.
  • add an entry in the [General] section of the updates configuration file, named LicenseIDCheckURL. This will be the URL of a script that does the actual validation.

NoteEven if you launch the updater with the license parameter, no action will be taken until you add the section in the configuration file.

The command could be something like: "updater.exe /silent HKLM\Software\MyEditor\LicenseValue".

The updater will do a POST with a string in the following format:

licenseid=%s&languageid=%u

The %s value represents the string read from the registry and the %u an unsigned value representing the language identifier of the user's Windows operating system. The language identifier is useful if you want the script to return a localized message.

The script must give an answer, so the updater can choose the following course of action. The answer must be in the form:

AnswerCode\nMessage

"Message" is an explanatory message, "\n" is the new line character and "AnswerCode" can be one of:

  • 601 - License is OK. The updater will go on and download the updates.
  • 602 - License is not valid, but the update can be downloaded. The updater will display the message and download the updates.
  • 603 - License is not valid and the update is not to be downloaded. The updater will display the message and stop.

License expiration check

An user may have a license that is valid for the product version on his machine but not valid for the newer version. The updater can check this and show a message to warn the user. After this, the user can decide whether to continue the installation of the update. For this:

  • add two parameters when checking for updates:
    • one is the registry value where the license is stored, as explained above.
    • the second is the license expiration date, in the form DD/MM/YYYY, where DD = the day, MM = the month and YYYY = the year.
  • add an entry in the update's section of the updates configuration file named ReleaseDate, that stores the release date of the update.

If the expiration date is prior to the release date then a warning is displayed.

NoteThese parameters must be specified last in the updater's command line.

Privacy Policy | Windows Installer | Search Engine Ranking | Link Analyzer