in reply to getSaveFile problems in Tk

Ok, once again, I just read the perldoc Tk::getOpenFile ;-)
the getSaveFile only opens a fileselect dialog for you. It will not even save a file, it just returns the filename and it's full path....

So you have to do this:

sub save { @types = (["Text files", [qw/.txt .doc/]], ["All files", '*' ]); my $file = $mw->getSaveFile( -initialfile => $save_file, -defaultextension => '.txt', -filetypes => \@types); open OUTFILE, ">$file"; print OUTFILE "whatever you want to save in that file"; close OUTFILE; &exit; }

Please try to name your sub's in lower letters. UPPER letters normaly used for Filehandles ..



-----------------------------------
--the good, the bad and the physi--
-----------------------------------