in reply to How to get PID of a process given its complete command line in windows
Take a look at the Win32::Process::List module, it's probably all you need. Alternatively, you could get away with a simple
my @proc_lines = `tasklist`;
but then you would have to parse the lines for the relevant info yourself. Win32::Process::List does that already.
UPDATE: A small example from the module documentation:
use warnings; use strict; use Win32::Process::List; my $plist = Win32::Process::List->new(); my $pid = $plist->GetProcessPid("explorer");
- Luke
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: How to get PID of a process given its complete command line in windows
by avj24 (Initiate) on Nov 10, 2014 at 15:55 UTC |