Skip to content
⌘ NSIS Forum Archive

KillProcDll addition please

6 posts

computechx#

KillProcDll addition please

Could someone add an ExitProc option to the KillProcDll plugin?
Rather than using terminate process use exitprocess.
If I understand it correctly using exit process will allow the exe to prompt you to for example to save changes before it closes rather than just terminating.
computechx#
I'm pretty sure FCT plugin won't work.
I don't have the class or title for the window, only the exe name.
Also not sure if it will work if there is no window, i.e. running in systray?
Afrow UK#
The way to find out is to write a program to loop through all the windows and print the class names (use EnumWindows).

Stu
Takhir#
I guess computechx had im mind ExitProcess() in the remote thread. Good idea, but may not work on Vista.
kichik#
I disagree. You're better off with TerminateProcess than injecting an ExitProcess call. You can never know in which state you'll catch the other process. You can drive into a deadlock. Even more, if FCT failed killing the process with messaging, you can already assume it's deadlocked.

As for Vista, it should only fail if you're trying to kill a protected process which is a bad idea anyway.

Afrow, that program is called Spy++ and it comes with Visual Studio. No need for a rewrite. There are also others available:

Winspector‚Ƃ́AƒEƒBƒ“ƒhƒEƒnƒ“ƒhƒ‹AƒNƒ‰ƒX–¼AƒEƒBƒ“ƒhƒEƒƒbƒZ[ƒW‚È‚Ç‚ðŽæ“¾‚µ‚Ä‚­‚ê‚éAƒvƒƒOƒ‰ƒ}‚ɂƂÁ‚Ä”ñí‚ɕ֗˜‚ȃtƒŠ[ƒ\ƒtƒg‚Å‚·B‚±‚̃y[ƒW‚ł͂»‚Ì‹@”\‚â—ÞŽ—ƒ\ƒtƒgAŒ»‹µ‚Ȃǂð‰ðà‚µ‚Ä‚¢‚Ü‚·B