Just write the fiilename as us script and file to open are in same location. my $filename="datafile.txt "; open my $FH,'<', $filename || die "no such files $!\n";
Regards Anirban Adhikary. On Sun, Dec 14, 2008 at 7:51 PM, itshardtogetone < itshardtoget...@hotmail.com> wrote: > Hi, > I wish to open a file datafile.txt which is stored in the same location as > the perl script, so how do I write it down? > > open (FILE,'<'," ") || die "no > such files $!\n"; > > -- > To unsubscribe, e-mail: beginners-unsubscr...@perl.org > For additional commands, e-mail: beginners-h...@perl.org > http://learn.perl.org/ > > >