in reply to Re^2: Where did I go wrong?
in thread Where did I go wrong?
See perlopentut for more.use strict; use warnings; my $FILE = undef; my $filename = 'C:\tmp\blah.txt'; open( $FILE, '<', $filename ) or die "Can't open $filename: $!"; while(<$FILE>) { ... } close $FILE or die "Close failed";
Also, it looks like you are running Win32. /tmp/blah.txt is not a proper Win32 filename.
Update: Thanks to cdarke for pointing out Win32 filename subtleties, where /tmp/blah.txt indeed is a possibly filename.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Where did I go wrong?
by cdarke (Prior) on Nov 14, 2007 at 10:43 UTC |