in reply to Printing out to a .txt file.

Have you tried reopening STDOUT? If you've already got a filehandle, it goes:
open(STDOUT, '>&MY7') or warn "$!";
otherwise, just open a file for writing normally, using STDOUT as your filehandle. You can save your STDOUT filehandle by
open(SAVE_STDOUT, '>&STDOUT');
first, then restore it with
open(STDOUT, '>&SAVE_STDOUT');
after.
Update: Oh, ikegami's looks much easier.

Caution: Contents may have been coded under pressure.