Hmm something seems to went wrong now...
I started programming something similiar to the taskmanager, you can press a button to kill a process but with this I have a problem...
{ pid2kill = global var type cardinal }
Process(Pid2Kill).Terminate;
{ I get the pid while someone clicked on an entry in the grid...
the grid then writes the pid into the global var pid2kill... }
when the button was clicked the grid gets updates and refilled without the terminated process of course }
The problem because of this is, when you start notepad and lets say wordpad too...
You can kill wordpad without any problem, while you have to click serveral times the button for killing another process maybe someone knows why...what ????
Hmmmm... I can only guess that there's something wrong with the PID. I'd suggest logging the PID you're trying to terminate and double checking it with the PID which the windows task manager shows (you can tell the windows task manager to show the process PIDs).