Home: Perl Programming Help: Win32 Programming Help:
Redirection in Win32::Process

New User

Oct 16, 2008, 3:10 AM

Views: 7251
Redirection in Win32::Process

I am trying to capture the output of the background process in a log file(redirectFile) using redirection but the redirectfile does not get created at all.

$cmd = "<exe name> > redirectFile";
Win32::Process::Create(my $obj, getExecVersion($proc), $cmd,

Please help in this regard.


Oct 16, 2008, 11:54 AM

Views: 7245
Re: [vmnaren] Redirection in Win32::Process

More than likely this is a problem:

my $obj

at that point $obj has no value even if it did previously. Remove the 'my' and retry your code.