Conditional execution inside of Merge Modules does not work - Advanced Installer Community
hhelbig
Posts: 20
Joined: Tue Feb 11, 2014 2:06 pm

Conditional execution inside of Merge Modules does not work

I'm using merge modules executing installed programs depending of conditions.
In my case these conditions are checking the installation behaviour of a feature: '&DBServer = 3'. 'DBServer' is a parent feature of the feature containing regarding merge module.

Used features:
Image

Merge module configuration:
Image

Configuration of merge module:
Image

As expected, if feature 'DBServer' is set to 0 files of merge module will not be installed. But build in execution of installed program will be started at any installation state of 'DBServer' feature.

My current 'work around' is ignoring the exit code. But this should not be the right way.
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Conditional execution inside of Merge Modules does not w

Hi,

I'm afraid I don't fully understand what is your scenario. Can you please tell us what version of Advanced Installer do you use and if your Merge Module is created with Advanced Installer?

The "Execute Program From Installed Files" dialog does not seem familiar to me and furthermore it has a localized button "Abbrechen", but all the Advanced Installer UI is in English.

It is possible that the condition you set for the installed program, to be evaluated when the package is launched and the "DBServer" feature is set to be installed at that point, but when the install state of the feature is changed the condition is not reevaluated and that is why the execution of the installed program is always triggered.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
hhelbig
Posts: 20
Joined: Tue Feb 11, 2014 2:06 pm

Re: Conditional execution inside of Merge Modules does not w

Can you please tell us what version of Advanced Installer do you use and if your Merge Module is created with Advanced Installer?
I'm using Advanced Installer Enterprise 11.1.
Merge modules were created by an Installshield Deployment Wizard of a bought product and modified by Wise Installation Studio.
It is possible that the condition you set for the installed program, to be evaluated when the package is launched and the "DBServer" feature is set to be installed at that point, but when the install state of the feature is changed the condition is not reevaluated and that is why the execution of the installed program is always triggered.
How to avoid this?

Is it possible to edit or import a merge module with AI? I did not found a way to do this. Therefore I'm using my obsolete Wise ;)

At Wise I'm able to change some parameters inside of a merge module. In this case I set sequence number of this entry to 1350. At setups build by Wise this is in every case AFTER completing installation process:
Image
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Conditional execution inside of Merge Modules does not w

Hi,
How to avoid this?
I'm not sure how this can be avoided, because I don't know how the "Execute Installed Program" feature works in a merge module created by Wise. I'm not sure when the specified condition is evaluated and if it can be reevaluated after the installation state of the feature is changed.
Is it possible to edit or import a merge module with AI?
Yes, in order to achieve this you can start Advanced Installer, go to "Merge Module" tab and use the "Import MSM Package" option.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
hhelbig
Posts: 20
Joined: Tue Feb 11, 2014 2:06 pm

Re: Conditional execution inside of Merge Modules does not w

I tried to import one of my Merge Modules.
By the way, import process stops with message 'Invalid MSI identifier string [SQL ANYWHERE 12 Server]' while 'Importing ModuleSignature table'.
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Conditional execution inside of Merge Modules does not w

Hi,

It seems that your merge module is not well formatted and Advanced Installer cannot import it.

You can edit your merge module using Orca or using the tool that you created it with and then try to re-import it in Advanced Installer.

The error says that the "[SQL ANYWHERE 12 Server]" string from the "ModuleSignature" table of the merge module is not correctly formatted. You can try to remove the spaces from that string and see if the problem persists.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”