in reply to Using a reference to a Filehandle

From perldoc -f print or print: Note that if you're storing FILEHANDLES in an array or other expression, you will have to use a block returning its value instead.

Following should work:
print {$fred->{outfile}} "This is another test\n";

artist

Replies are listed 'Best First'.
Re: Re: Using a reference to a Filehandle
by mildside (Friar) on Jul 09, 2003 at 05:56 UTC
    Thank-you for your response, your suggestion does indeed work.