in reply to Redirecting STDERR to a variable
(at least I think that is correct, most of my Perl stuff is at work right now).open (STDERR, ">>error.log") or die "Cannot redirect STDERR to error.l +og file";
Update: Actually, in order to make the most use out of this, you will need to use qx// to run your executable. If you use system() or exec(), you may not always capture all the information you need or want. Thus:
open (STDERR, ">>error.log") or die "Cannot redirect STDERR to error.l +og file"; qx!c:\path\to\executable!; close (STDERR);
Of course, there is probably a better way to do all this that I have not yet discovered :-)
|
|---|