cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Witness_CM
Level 2

[Urgent] Can not execute Custom Event in Silent mode

Hi experts,

I created an installer file from InstallShield Universal 11 or InstallShield MultiPlatfrom 11.5 project. I also have response file.

I executed the command line to run that installer in silent mode:

D:\>setupwin32.exe -options-record D:\record2.txt

But all Custom Event didn't run. It looks like I forgot something.

Please give me your suggestion.

Many thanks,
Labels (1)
0 Kudos
(3) Replies
enanrum
Level 9

For one - that does not run the install in silent mode; that creates a response file, which if you have custom dialogs, you have to create custom code to actually write out the custom values you have to the response file.

If you have your custom actions set up correctly in you sequence - they should run in all modes: silent, console and gui. How are you calling these CA's?
0 Kudos
Verint_CM
Level 2

Yes, you are right. That does not run the install in silent mode, hat creates a response file.

Could you please to give me an example about custom code to actually write out the custom values to the response file.

And I still have one more problem in silent mode, the installer doesn't copy files\folders. Do you know the root cause of this problem ?

Many thanks and very appreciate your help
0 Kudos
enanrum
Level 9

Here's a custom one I used for a Product Key Dialog:

    public void generateOptionsEntriesProductKey(com.installshield.event.ISOptionsContext context)
{
String value = null;
String option = null;
Vector optionEntries = context.getOptionEntries();
try {
ProductService pService = (ProductService) context.getService(ProductService.NAME);
if (context.getValueType() == WizardBean.TEMPLATE_VALUE) {
value = LocalizedStringResolver.resolve("com.installshield.wizard.i18n.WizardResources","WizardBean.valueStr");
} else {
value = context.getWizard().getServices().getISDatabase().getVariableValue("PRODUCTKEY");
}
option = "-V PRODUCTKEY=\"" + value + "\"";

String DisplayName = context.resolveString("$P(MYPROJECT.displayName)");
String doc = "The Product Key for the " + DisplayName;
optionEntries.addElement(new OptionsTemplateEntry("Custom Dialog: " + context.getPanel().getName(), doc,option));
} catch (ServiceException e) {
LogUtils.getLog().logEvent(this, Log.ERROR, e);
}
}
0 Kudos