Is it possible to create an array of file handles?.. like so:
This complies correctly.. and even runs. But when we try to go through each file and pattern match a line for data retrival, it doesn't find the line even when matching a literal in the code to a literal in the file.
Anyone able to give us some insight on this?
Code:
@files = ("file1", "file2" ,"file3");
@fhs = new FileHandle;
for( $i = 0; $i <= @files; $i++)
{
open($fhs[$i], "<$files[$i]");
}
This complies correctly.. and even runs. But when we try to go through each file and pattern match a line for data retrival, it doesn't find the line even when matching a literal in the code to a literal in the file.
Anyone able to give us some insight on this?