Showing results for 
Show  only  | Search instead for 
Did you mean: 
Level 6

Unable to get silent install section name.


I'm having problems setting up a silent install.

I have created an InstallScript MSI project.
The installation appears to work perfectly during a normal UI installation.

Some of the dialogs displayed during the installation have been invoked via an InstallScript Custom Action.

I am unsure what to set nvDlg to for the call to SdMakeName (tried 1 and 0 after trying leaving it uninitialized as in the documented example);
After the call to SdMakeName svSection is blank and nvDlg is unset;
When I run this in record mode i.e. supplying /r flag on command line I get no extra output to the .iss file.

I list only what I believe to be the pertinent lines below:

function PLSetup(hInst) // This is the start of the CA function
STRING svSection;

szDlg = "PLSetup";
nvDlg = 1;

SdMakeName (svSection, szDlg, "", nvDlg);

My understanding of the SdMakeName function is that svSection is created on returning from the function and it used szDlg and nvDlg to creat the svSection name.

Q. Why is svSection still blank after SdMakeName call ?
Q. Why am I getting no output for the dialog to the .iss file I specify on the command line during record mode ?

Thanks in advance for any assistance given.
Labels (1)
0 Kudos
(1) Reply
Level 10 Flexeran
Level 10 Flexeran

Response files are not supported from InstallScript custom actions. The reason for this is each custom action runs its own instance of the InstallScript engine that is not related to the instance running the dialogs for InstallScript MSI installations. The custom actions don't have access to any information from the main engine instance, including information on whether a response file is being read in or written out.

In general we do not recommend calling InstallScript dialogs in any manner from InstallScript custom actions. These will have no relation to the main setup and cannot control back or forward dialog movements. If a dialog needs to be displayed from InstallScript MSI installations it should be called from one of the predefined events; for example, from OnFirstUIBefore to collection input before the MSI installation starts or from OnFirstUIAfter to collect input after the MSI installation has completed.
0 Kudos