I have several CA with possible MessageBox(es).
For instance I have a CA which checks whether a process is running and suggests to kill it if the user wants.
What is the best to do to avoid all MessageBoxes when I run a silent install?
Is there a way to know from within my script in which mode the installation is started?
This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Get rid of CA MessageBox(es) during silent setup
Started by
kgiloo
, Dec 21 2006 14:32
5 replies to this topic
Posted 22 December 2006 - 01:59
Yes, you can check the value of the UILevel Property.
Regards
-Stein Åsmul
-Stein Åsmul
Posted 22 December 2006 - 06:48
For this aim I use Session.Message method.
This method automatically runs in silent mode (messages go to the log).
For example:
This method automatically runs in silent mode (messages go to the log).
For example:
CODE |
iNum = Session.Property("DIRMSIMSGNUMBER") iButtons = Session.Property("DIRMSIMSGBUTTONS") Set oRec = Session.Installer.CreateRecord(1) oRec.IntegerData(1) = CInt(iNum) svRez = Session.Message(CInt(iButtons), oRec) oRec.ClearData Set oRec = Nothing Session.Property("DIRMSIMSGREZ") = svRez |
This code gets iNum - number of exception from Error table
iButtons - buttons to show (the same as for MsgBox function).
Posted 22 December 2006 - 11:42
I prefer MsiProcessMessage / Session.Message.
This function detects invisible installs and acts upon that. More important: in case of a full UI, you know for sure that the message is not shown behind the main window.
This function detects invisible installs and acts upon that. More important: in case of a full UI, you know for sure that the message is not shown behind the main window.
Posted 08 January 2007 - 12:24
I thank you for your help.
I used the function MsiProcessMessage successfully.
For the silent install I found out that the function returns '0', which enables me to manage specific actions in this mode.
I noticed that the message strings were sent anyway to the log file in silent mode.
Do you know if there's a way to log some messages for specific modes only (silent install for instance)?
Thanks in advance
I used the function MsiProcessMessage successfully.
For the silent install I found out that the function returns '0', which enables me to manage specific actions in this mode.
I noticed that the message strings were sent anyway to the log file in silent mode.
Do you know if there's a way to log some messages for specific modes only (silent install for instance)?
Thanks in advance
Posted 08 January 2007 - 18:28
You could embed your logging code in an if statement that checks the value of the UILevel property.
Stefan Krüger
InstallSite.org twitter facebook