smanicka has asked for the wisdom of the Perl Monks concerning the following question:
This is what happens: It repeats this message 7 times:"Usless Use of a constant in void context at move_files.pl line 3" and it opens the text file.Then when I close the file,it says "cannot do this at move_files.pl line 4"#!usr/bin/perl -w use strict; my $cmd=qw(lpr -S SYSTEMX -P QGPL/SPYVIEW -o l C:\\ABCDEFGH.txt); system($cmd) or die "cannot do this";
Could anybody tell me where I am wrong please.It works fine when i just use the lpr command from my command prompt.I use activestate perl and am on a windows machine. Thanks
-SandhyaUPDATE: It now does not show up with the message 7 times.But other than that it says cannot do this.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: lpr command from perl not working.
by bingos (Vicar) on Feb 11, 2009 at 21:25 UTC | |
by smanicka (Scribe) on Feb 11, 2009 at 21:30 UTC | |
by aaron_baugher (Curate) on Feb 11, 2009 at 21:44 UTC | |
by smanicka (Scribe) on Feb 11, 2009 at 21:49 UTC | |
|
Re: lpr command from perl not working.
by linuxer (Curate) on Feb 11, 2009 at 21:50 UTC | |
by smanicka (Scribe) on Feb 11, 2009 at 21:56 UTC | |
|
Re: lpr command from perl not working.
by repellent (Priest) on Feb 11, 2009 at 21:28 UTC |