spearsp
Posts: 9
Joined: Thu Nov 14, 2013 2:28 pm

Customise Dialog Flow Based On Feature Selection

Hi

I am stuck again, trying to customise the flow of dialogs based on the selected features. I have checked the posts on conditionally displaying a dialog using the "Show only if" menu selection, but this only works if there is only one dialog in the stream that needs to be conditionally displayed. This is probably best described by example: I have 4 features, which we will name F1, F2, F3 and F4. In my installation, each feature is a module, which has its own settings page in the installer.

In my test project, I set up the features, and created 4 new dialogs (F1Dlg, F2Dlg, etc) between the Customize page (which I pulled out of the Setup Type dialog) and the VerifyReadyDlg dialog. Run the test, all looking fine. Then I added a "Show only if" condition on F1Dlg, to show only if &F1=3. Without feature F1 selected, it jumps straight to F2Dlg, and with F1 selected, it shows F1 and then F2. No problem there. However, if I repeat that process for F2, F3 and F4, and then select all features for installation, it shows F1Dlg and then jumps straight to VerifyReadyDlg.

Is it possible to show a dialog by name, so that I can use a custom action to determine the next dialog in the sequence (e.g. Set property Value LM_NEXT_DIALOG="F2Dlg"; ShowDialog [LM_NEXT_DIALOG])? Failing that, is it possible to show a dialog via a call to MsiDoAction from within the custom actions DLL? Is it possible to simply tie a dialog to a feature, without having to manually code the flow individually into every single next/back button?

I have attached a scratchpad project that illustrates what I am trying to accomplish.

Thanks,
Peter
Attachments
Scratchpad.aip
(22.2 KiB) Downloaded 304 times
Eusebiu
Posts: 4959
Joined: Wed Nov 14, 2012 2:04 pm

Re: Customise Dialog Flow Based On Feature Selection

Hi Peter,

In order to achieve what you want you can use the "Display a specific dialog" control event on the [Back] and [Next] buttons of the dialogs, as many times as necessary and also set the appropriate conditions for these events.

For more details you can take a look on the attached AIP file that I modified to fulfill your needs.

Let us know if this helped, otherwise give us more details about your scenario.

Best regards,
Eusebiu
Attachments
Scratchpad.aip
(21.39 KiB) Downloaded 352 times
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”