use warnings; use strict; use Win32::Process; my $ProcessObj; Win32::Process::Create ( $ProcessObj, # Process handle "C:\\Perl\\bin\\perl.exe", "C:\\Perl\\bin\\perl.exe gash1.pl", 0, # inherit handles boolean NORMAL_PRIORITY_CLASS, # Creation flags "."); my $pid = $ProcessObj->GetProcessID(); my $exitcode = 37; print "Hit to continue...."; ; Win32::Process::KillProcess($pid, $exitcode);