PDA

View Full Version : LaunchAppAndWait self-exclusive??



Nc_At_Alta
06-07-2005, 05:26 AM
Hey

I am having issues with 2 LaunchAppAndWait (LAAW) statements in my OnFirstUIAfter. If the first one is called, the second one will ALWAYS fail! :mad:

The first calls
----
LaunchAppAndWait( tmpDrive ^ @DB2_PATH ^ "\\setup.exe", "/m /u " + TARGETDIR ^ "SQL\\PROD_PE.rsp",LAAW_OPTION_WAIT);
----
in order to do an unattended DB2 installation, and the second one will then perform setups.
It doesn't matter what I call in the second LAAW, though usually it is the DB2 command prompt request. Calls to other processes fails as well.

A later call (last statement in OnFirstUIAfter) calls Notepad, and this actually succeeds. :confused: - only thing is that it is preceeded by a call to SdFinish(). This should not really matter to LAAW!

I am, as you can probably figure out, at a loss for this behaviour. If anyone has encountered a similar thing, please let me know... :o

Best regards,
Nc.

Somebody
06-07-2005, 10:03 AM
Are you by chance running into this problem described in the help for the LaunchAppAndWait() function:

"When using LaunchAppAndWait to launch a second installation, the second installation should use the same or an earlier version of the installation engine. (This is because the launching installation locks engine files that a launched installation would attempt to overwrite if its engine version was later.) "

Nc_At_Alta
06-07-2005, 10:27 AM
No, not at all - the other setup is not interfering :)
It actually manages to install just fine, but it seems that the install-script has issues finding the file I want it to execute. I have tracked it down by a
----
MessageBox( FormatMessage( LAAW_PARAMETERS.nLaunchResult), INFORMATION);
----
to be a problem with either paths or simply IS not being able to see the file :confused:

I tried a
----
if(Is(FILE_EXISTS, szFileName))
----
with szFileName being set to the correct path+executable (remembering to escape my backslashes), and that one does not run either. I can copy-paste the value of szFileName into a command-prompt and get it to run there, but thats hardly scriptable....

Even a call to
----
SendMessage (HWND_BROADCAST, WM_WININICHANGE, 0, pEnv );
----
did not help, though I thought it would reload the path-settings. I suspect this is due to IS not having any open dialogs at the time, though I would expect it to still have a window to recieve the message in.

So, I am still at a loss, but I have gotten a bit further!

/Nc.