in reply to Help with formatting a text file

Hi Folks, Thank you for all the help! Appreciate very much. I think the best approach would be to simply use:
foreach my $key (keys %datahash) { format NEWFORMAT = ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< @###.## $key, @datahash{$key} ^<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< ~~ $key . write(OUTFILE); }