You are correct in saying -> (you appear to want to test the result of the command, not the result of the system call).
I do currently spool the STDERR and STDOUT to a file but I'm not to sure how to put this in a variable for only selected cases
Here is how I spool the STDERR & STDOUT to File. I'll also look at If you want to trap the output of the command, you should be using backticks or qx instead (see perlop).
open (STDOUT, "> $system_folder\\system.log") or die "Can't redirect s
+tdout: $!";
open (STDERR, ">&STDOUT") or die "Can't dup stdout: $!";
Thank you
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.