Manish Uskaikar wrote:

command line:

$perl man.pl manish



perl script

#!/usr/bin/perl;
($inputfile) = @ARGS;

Could anyone tell me how to accept the commandline parametes this does not seem 
to work.

@ARGV and not @ARGS is an array
so you have to use it by element.
In your case the name of the input file (manish)
seems to be  the first argument.

So youshould use this code:

($inputfile) = @ARGV[0];


HTH

Remo

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to