http://www.perlmonks.org?node_id=990109


in reply to Re: Win32::Process::Create fails when i use ">" to redirect the screen output to a file
in thread Win32::Process::Create fails when i use ">" to redirect the screen output to a file

I am open to correction, but I believe that > would not be a part of the command line passed to notepad, but rather would be passed to your shell (cmd.exe, cygwin's sh, whatever).

Also I don't think that notepad.exe actually outputs anything to the console under usual circumstances, being a completely GUI application.

I do not believe cmd.exe supports 2>&1 style redirects (apparently it does, see here, thanks for the headsup), so you would have to be using cygwin's sh or perhaps SUA perl. In that case, why aren't you just using system, qx or open?