in reply to Detecting read errors whilst reading from a network drive
The code you gave is exactly the code I would use to open and read/process all the records in a file. Except I would put a message in my die - something like this:
my $abs_filename = "x:\\myfiles\file.txt"; open(RESTART, "<$abs_filename") or die "Can't open $abs_filename: $!"; while (<RESTART>) { # do something with $_ }
|
|---|