Detect end of of .exe
Detect end of of .exe
(OP)
I am using a proprietary script to launch a series of software installations chosen by the user from a menu. The installations are done through either msiexec.exe or setup.exe. It is vital that one installation has completely finished before the next begins. However, some of them have other processes embedded whose behaviour cannot always be predicted - such as external database access right at the end - which mean that say just setting a timer or searching for the new registry uninstall key, won't work. I looked into Windows Scripting Host run method, but then discovered that the proprietary script doesn't support WSH.
How could I detect the real end of .exe with a Windows API call?
Many thanks
How could I detect the real end of .exe with a Windows API call?
Many thanks
RE: Detect end of of .exe
Somethink like this?
Brian
CODE
lcProcess ="MyEXE"
loWMISrv = Getobject("winmgmts:{impersonationLevel=impersonate}!\\.\root\cimv2")
colProcessList = loWMISrv.ExecQuery("Select * from Win32_Process")
For Each loProcess In colProcessList
IF loProcess.name = lcProcess
* then keep waiting
ENDIF
Next