open(STDOUT,">","myfile.xml") or die "Cannot redirect STDOUT to myfile.xml - $!";