PDA

View Full Version : How can I terminate a process before uninstalling



erikheuer
06-02-2004, 03:50 PM
I have a basic msi project where I would like to terminate (kill) a process before starting to remove files (REMOVE="ALL") during an uninstall. Is there a way to create a custom action or other means to terminate a process using Installshield X?

- your suggestions are greatly appreciated.

David Thornley
06-03-2004, 08:09 AM
Basic MSi projects will prompt to shut down any processes that are locking file that you need to install. The quid pro quo is that MSI must be able to trace that process back to a window handle...so it won't shut down a service running in the background.

Past that I would recommend writing a custom action DLL that does this. There are Windows API's for killing processes.