PDA

View Full Version : Custom Dialog - enabling controls programmatically



djwillfund
04-03-2002, 10:35 AM
Hi, all. I am creating some custom dialogs for an install I am doing, and I seem to be stuck. I am trying to determine if it is possible to programmatically access the properties for various controls. In this particular case, I have a hierarchy of radio button groups. Depending on which main button they select, I want to make different sub-groups accessible (or not accessible as the case may be) by enabling or disabling them (i.e. set the 'Enabled' property to 'FALSE'). But I need to do it from within the script as the install is running, not at design time.

Along the same lines, I am trying to disable the next button on my form, and the 'Disable(NEXTBUTTON);' call in Installscript doesn't work on this custom dialog.

Any assistance is greatly appreciated.

huntant
04-03-2002, 11:02 AM
If you are working with a basic project, then you can set that in the behavior settings for your dialog.
Select the control that you want to hide/show. Click on the Conditions tab at the bottom of the screen. Set the action to what you want to happen, and enter the condition that will trigger that action.




Anthony

djwillfund
04-03-2002, 02:30 PM
Thanks for the reply. Unfortunately, this is a Standard Installshield project, not a basic MSI project. I'm not sure where to make the modifications you mention in a standard install.

huntant
04-03-2002, 02:55 PM
Unfortunately I don't work with standard projects at all. I'm trying to code as little as possible. It also allows the user to run the .msi and .msp files directly without having to run setup.exe or update.exe.




Anthony

KathyMorey
04-03-2002, 04:12 PM
In a Standard project, you can use scripting to accomplish what you want. Take a look at the Custom Password examples in the sample directory for a start.

HTH
Kathy