in reply to Re^2: Handling multiple output files simultaneously using arrays of filehandles and filenames
in thread Handling multiple output files simultaneously using arrays of filehandles and filenames
... #Output line of matching data to output file for the relevant sector print $fh[$dataSector] "$mydata\n"; ...
So the syntax you need to use is
print { $fh[$dataSector] } "$mydata\n";
(extra spacing around the curlies just for visibility/clarity).
Give a man a fish: <%-{-{-{-<
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: Handling multiple output files simultaneously using arrays of filehandles and filenames
by Cosmic37 (Acolyte) on Jan 22, 2021 at 14:01 UTC | |
by AnomalousMonk (Bishop) on Jan 22, 2021 at 19:49 UTC |