in reply to Capture PID from child process on Windows.

As u need to kill the process if it hangs(meaning u need to control process), the process you create must be an asynchronous process.
The following is a code snipet of the same under windows
use strict; use Win32::Process; my ($processObj, $pid); Win32::Process::Create($ProcessObj, "C:\\foo\\Setup.exe", "Setup.exe", 0, NORMAL_PRIORITY_CLASS,".")|| die "$!\n"; $pid = $ProcessObj->GetProcessID();
Using the pid you can control the process.
To kill the process say,
$ProcessObj->Kill($exitcode);
Amar