cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
bartek
Level 3

OnMsiSilentInstall

Hello Everyone,

I'm launching msi file in silent mode:
>>my_install.msi /q

I would like to handle this mode in script. But application doesn't run any of predefined functions like OnBegin, OnEnd etc...
So I overwriten OnMsiSilentInstall function but still nothing. Instalation in silent mode doesn't run this part of script code. What am I doing wrong??
Could you write me how to execute some part of script in the silent mode?

This is InstallScript Msi Project.

Thanks!!
Bartek
Labels (1)
0 Kudos
(7) Replies
amitha
Level 3

what ever custom actions like Onbegin and etc..need to be in execute sequence unde sequences.Only then ,they will run in silent mode.also give UILevel=2 for condition
0 Kudos
bartek
Level 3

As I understood from the documentation OnMsiSilentInstall should be called automatically, but it is not.
So, I added Custom Action in Installation in Execute Sequence. In this Custom Action I'm running my script function, but it still doesn't work.
Wherever I added this action: in User Interface or Execute sequence it is not starting.
The only one effect is when I change Return Processing to asynchronous my installation hungs up.

What I want to do? In the silent mode I want to check something in Registry and if I found it I want to terminate installation.

BF
0 Kudos
Not applicable

You can do this in 3 steps.
Step 1. Use IS system search to find the registry key and store it in a property
Step 2: Create an error custom action and use the property in install executes condition
Step 3: Use execute sequence to Schedule the ‘Error CA’ just after the application search.
0 Kudos
bartek
Level 3

Hi,
I don't know why but System search doesn't find proper value.
See this screencast
I have in registry version 9.5.0.0
Only when I have condition INSTALLEDVER="" the error message is displayed. So, it means that value is not propperly readed from the registry.
What am I doing wrong?

Bartek
0 Kudos
bartek
Level 3

How to compare two version??
if I will use < operator 9.1.0 will be greater than 10.1.0

Bartek
0 Kudos
bartek
Level 3

INSTALLEDVER>ProductVersion OR (INSTALLEDVER<<"10." AND ProductVersion<<"9.")

🙂

Thanks!!
0 Kudos
Not applicable

You can do this without a CA (Custom Action). Go to direct edit -> add your condition in the condition filed of launchcondition table, and respective error message in the description field. (This is same as General Information -> General -> condition.)

Always make sure that launchcondtion action scheduled after appsearch action. By default it comes after the appsearch.
0 Kudos