Slowly learning here …. I tried both of your suggestions, which work fine as long as notepad.exe is what I’m trying to kill. But as it turns out, the process I’m trying to kill is one of the files I’m trying to install (which wasn't made clear in my original post). That is, the when I uninstall this product I want to first check to make sure the process isn’t running, and kill the process if it is. What seems to be happening is that the Files In Use dialog and function are being called by the installer before my Custom Action is being called, so I end up seeing the Files In Use dialog pop up anyway. I’m not sure where in the sequence of things that the Files In Use check is being called. But I tried something a little different to work around the issue. Since this is an InstallScript MSI project, I can get to the Dialog Source in the InstallScript section under Behavior and Logic. By commenting out the While Loop, I effectively removed the loop that waits for the user to click a button, and forced the OK button to be “pressed” in the code, so the dialog exits about as soon as it’s opened, with the default values selected. The Files In Use dialog closes almost immediately and the process (the one I’m uninstalling) is killed. Works like a charm.
... View more
I've created a Kill-Process Custom Action per the instructions provided in the Help file. I'm using the KillProcessDeferred function, I created a New Property which matches the name of the Custom Action, and added the name of the process that I want to kill. I inserted the Custom Action in the Installation Execute sequence between the "InstallInitialize" and the "InstallFinalize" sequences. I "think" I've done everything correctly. Yet it doesn't work. Instead I'm prompted by the InstallShield default screen which displays the running process, and gives me the two radio-button choices to kill the processes now or later. I want the processes to be killed without the user having to intervene. So I see in the discussion threads that the InstallSite.org has samples to use for doing this (List and Shut Down Running Applications.) Apparently this method does work, but the InstallShield doesn't? Has anyone had any success with using the CA, and if so, what else is missing from the instructions? Thanks!
... View more