
KevinR
Veteran

Mar 28, 2008, 10:19 PM
Post #8 of 30
(17497 views)
|
You are only using the name of the file you want to read ($current_file): open ($IN, $current_file) or die "$!"; so that file would have to be in the same directory as the script or you have to change directory to the directory where to $current_file resides or use the full path to the file: open ($IN, "path/to/$current_file") or die "$!"; Also, in your first post in this thread, the filename has an underscore in it but in the code you posted there is no underscore in the filename. So remove the underscore in this line if it should not be there: my $current_file = sprintf "mv_%07d.txt", $file; -------------------------------------------------
(This post was edited by KevinR on Mar 28, 2008, 10:22 PM)
|