Silent install launches application
I'm trying to silently install an application that launches once the install is completed.
Is there any command line parameter for setup.exe to stop the application launch?
Thank you for your help.
RussC
Is there any command line parameter for setup.exe to stop the application launch?
Thank you for your help.
RussC
0 Comments
[ + ] Show comments
Answers (6)
Please log in to answer
Posted by:
anks_09
15 years ago
Hi,
What i suggest you can first try to find out wether any msi is wrapped into that setup.exe.If msi would be there then there would be a custom action which would be after InstallFinalized that would be launching any executable.Check this out first then we could analyzed more abt it..
Regards,
anks_09
What i suggest you can first try to find out wether any msi is wrapped into that setup.exe.If msi would be there then there would be a custom action which would be after InstallFinalized that would be launching any executable.Check this out first then we could analyzed more abt it..
Regards,
anks_09
Posted by:
RussC
15 years ago
My first post on this forum...
Not enough information here, let me see if I can expand things a bit.
- There is no MSI files present or created during the install, it's just a setup.exe with .cab file.
- I have not been able to find a command line variable to stop application launch
- I would like to know if lines can be inserted into the setup.iss file to prevent the application launch
- I'm using setup.exe /s /sms /f1"z:\setup.iss" /f2"C:\Install-app.log" This works fine apart from starting the application on completion.
- the application is eSentinel Roster, a resource scheduling application
Once again thanks for all the help.
Russ.
Not enough information here, let me see if I can expand things a bit.
- There is no MSI files present or created during the install, it's just a setup.exe with .cab file.
- I have not been able to find a command line variable to stop application launch
- I would like to know if lines can be inserted into the setup.iss file to prevent the application launch
- I'm using setup.exe /s /sms /f1"z:\setup.iss" /f2"C:\Install-app.log" This works fine apart from starting the application on completion.
- the application is eSentinel Roster, a resource scheduling application
Once again thanks for all the help.
Russ.
Posted by:
AngelD
15 years ago
How about launching a script to check for the process being started and terminate it at once?
run it prior to launching setup.exe
ex.
(You may want to change the MaxAllowedRunTime and WatchForProcessName value)
run it prior to launching setup.exe
ex.
(You may want to change the MaxAllowedRunTime and WatchForProcessName value)
Const MaxAllowedRunTime = 120 '// if process has not started in 120 seconds then exit script
Const WatchForProcessName = "notepad.exe" '// process name to look for
Dim WaitForNotificationRequest, WMIService, Sink
Set WMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" _
& ".\root\cimv2")
Set Sink = WScript.CreateObject("WbemScripting.SWbemSink","SINK_")
WatchForProcessNameExecutionAndTerminate(WatchForProcessName)
Sub WatchForProcessNameExecutionAndTerminate(Name)
Dim WMIQuery, ElapsedRunTime
WMIQuery = "SELECT * FROM __InstanceCreationEvent " & _
"WITHIN 1 WHERE TargetInstance ISA 'Win32_Process' " & _
"AND TargetInstance.Name = '" & Name & "'"
WMIService.ExecNotificationQueryAsync Sink, WMIQuery
ElapsedRunTime = 0 : WaitForNotificationRequest = True
While WaitForNotificationRequest
ElapsedRunTime = ElapsedRunTime + 1
WScript.Sleep(1000)
If ElapsedRunTime > MaxAllowedRunTime Then
EndNotificationRequest()
End If
Wend
End Sub
Sub SINK_OnObjectReady(wmiObject, wmiAsyncContext)
Call TerminateProcessByProcessId(wmiObject.TargetInstance.ProcessId)
EndNotificationRequest()
End Sub
Sub EndNotificationRequest()
WaitForNotificationRequest = False
Sink.Cancel()
End Sub
Function TerminateProcessByProcessId(ProcessId)
Dim ProcessList, Process
Set ProcessList = WMIService.ExecQuery("SELECT * FROM Win32_Process WHERE ProcessId = '" & ProcessId & "'")
For Each Process in ProcessList
Process.Terminate()
Next
End Function
Posted by:
Foleymon
15 years ago
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
so that the conversation will remain readable.