in reply to Problem in my coding

I already told you this in the chatterbox.

It's easiest is to redirect the output. Many shells allow you to capture the error output via

2> errorlog
. Or call your program via
my @output = `$program 2>&1`
Otherwise, look at IPC::Run.

Replies are listed 'Best First'.
Re^2: Problem in my coding
by bart (Canon) on Mar 16, 2008 at 20:56 UTC
    In addition, check the value of $? after the system call. It contains a processed value of the exit code of the program (divide by 256 and you'll get very close), it'll be non-zero if there was an error.