We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

rkulp
Posts: 48
Joined: Mon Feb 26, 2007 10:50 pm

License Key Dialog

I would like to insert a dialog into the seup package that will accept a 25 character license key (preferably in five sets of five characters) or skip the step for those who are evaluating the software and don't have a license key. Currently this is done in the program but it may be cleaner to do it during installation. Does anyone have a suggestion on how this can be done? The key would be copied to the registry. :?:
Ionut
Posts: 605
Joined: Tue Nov 22, 2005 11:29 am
Contact: Website

Hi Richard,

I would suggest that you use the predefined "UserRegistrationDlg" dialog for this purpose. You can add it to your project by selecting "Use Serial Validation" in the Serial Validation page. See the following page for details on how to configure the Template for the serial:

http://www.advancedinstaller.com/user-g ... -page.html

Switch to the Dialogs page and add a checkbox to the "UserRegistrationDlg" dialog. Make the following changes for this checkbox:
- Text: "Install the trial version" (or something similar)
- Property Name: "TRIAL_CK" (for instance).
- Value: "YES"

The idea would be to disable the MaskedEdit control when the checkbox is selected. In order to achieve this, define the following Control Conditions for the MaskedEdit control:

Code: Select all

   Condition        |    Action
--------------------|-----------------
  TRIAL_CK="YES"    |   Disable
  NOT TRIAL_CK      |   Enable
In your serial validation DLL retrieve the value of the "TRIAL_CK" Property (using the "MsiGetProperty" function) and test its value. If the value is "YES" (that is, the checkbox is checked), set the "SERIAL_VALIDATION" Property to "TRUE" (using the "MsiSetProperty" function) and then return, without performing any validation of the serial entered by the user (stored in the PIDKEY Property).

That is, if the checkbox "Install the trial version" is checked, no serial validation is performed and the next dialog will be displayed. See the following page for a sample serial validation DLL Custom Action:

http://www.advancedinstaller.com/user-g ... n-dll.html

In the Registry page create a registry value specifying the Formatted value [PIDKEY] as its data.

Hope this helps.

Regards,
Ionut
Denis Toma
Advanced Installer Team
http://www.advancedinstaller.com/
rkulp
Posts: 48
Joined: Mon Feb 26, 2007 10:50 pm

Ionut,

Thanks.

Return to “Common Problems”