programatically identify procs using a specific file and kill them

P

Phil Bridges

I need to be able to identify processes using a specific file (not
dll) and kill them off.

Currently I can do this manually on win2k by running Process Explorer
(procexp.exe), searching for the file and then killing them, but I
need to be able to do this programatically not manually, any ideas ?.

KILL doesnt seem to be able to do the job as it only matches patterns
on process names and TLIST only matches on .dll's.

Thanks.
Phil.
 
M

Mark V

Phil Bridges wrote in @posting.google.com:
I need to be able to identify processes using a specific file (not
dll) and kill them off.

Currently I can do this manually on win2k by running Process Explorer
(procexp.exe), searching for the file and then killing them, but I
need to be able to do this programatically not manually, any ideas ?.

KILL doesnt seem to be able to do the job as it only matches patterns
on process names and TLIST only matches on .dll's.

Maybe it's me, but I don't quite understand.
If you need a list of process names and PID's
pulist.exe (ResKit)
tlist.exe (ResKit & SupportTools)
pslist.exe ( www.sysinternals.com )
and others
For process Kill:
kill.exe (ResKit & SupportTools)
pskill.exe ( www.sysinternals.com )
and others

Mostly you need to know the process "name" (or PID) to kill it.
tlist.exe does output full executable filenames though.

Perhaps if you can say more about what you have to start with...

If you have only a known filename.DLL to start, look at listdlls.exe
( www.sysinternals.com ).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top