Get a reference to a file handle by using '$ioreference = *name{IO};'
open FILEHANDLE, ">file.dat" or die "Couldn't open file."; $ioref = *FILEHANDLE{IO}; print $ioref "Hello"; close $ioref;