/build/static/layout/Breadcrumb_cap_w.png

close a running process on install

hi guys
ive created successful packages for microsoft office 2003 which seems to work fine so far
we have a slight problem though, i need to get the exe file i have created in wps to close certain running processes - internet explorer and that sort of thing - otherwise my package gives an error that it cant install
im not sure of the exact processes at this time - ill find that out soon - but is there a way this can be done so the package can install silently?
thanks for any help

0 Comments   [ + ] Show comments

Answers (1)

Posted by: MSIPackager 19 years ago
3rd Degree Black Belt
0
Well one way is to use an embedded vbscript custom action - here's and example which stops the diagnose.exe process but you can change that to whatever running process you want to stop (e.g. iexplore.exe)

--------------

strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set colProcessList = objWMIService.ExecQuery _
("SELECT * FROM Win32_Process WHERE Name = 'Diagnose.exe'")
For Each objProcess in colProcessList
objProcess.Terminate()
Next

--------------

Presumably though you are using the vendor install for Office 2k3? If so I'm surprised you need to bother with this stuff as I'd have thought the MS install would stop any processes as required?!

Good luck,
Rob.
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ