in reply to Re^7: Perl tk - How to integrate external scripts
in thread Perl tk - How to integrate external scripts
Maybe this the problem ?# Entry Window $init = my $mw = new MainWindow; $label = $mw -> Label(...) # The START button: my $button = $mw -> Button(...,-command=>\push_button); + sub push_button { my $mw = new MainWindow; $mw -> geometry ("1200x600"); # Menu bar $mw->configure(-menu => my $menubar = $mw->Menu, -background => 'white'); my $file = $menubar->cascade(-label => '~File'); my $edit = $menubar->cascade(-label => '~Edit'); my $help = $menubar->cascade(-label => '~Help'); my $open; $mw-> Button (-text =>'Open', -command =>\&open_file)->place(-x=>240, +-y=>35); $mw-> Button (-text =>'Get Statistics', -command =>\&get_statistics)-> +place(-x=>320, -y=>35); MainLoop; sub open_file {$open = $mw->getOpenFile( -filetypes => $types_OPEN, -defaultextension => '.sff'); $te->Load( "$open");} sub get_statistics { my $fastafile= $open; print STDERR "selected file: $fastafile\n"; }; $te = $mw->Scrolled( .....); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^9: Perl tk - How to integrate external scripts
by Eliya (Vicar) on Jan 31, 2012 at 14:06 UTC | |
by Giorgio C (Novice) on Jan 31, 2012 at 14:40 UTC | |
by Giorgio C (Novice) on Feb 01, 2012 at 11:35 UTC | |
by Anonymous Monk on Feb 01, 2012 at 11:38 UTC | |
by Giorgio C (Novice) on Feb 01, 2012 at 12:20 UTC | |
by Eliya (Vicar) on Feb 01, 2012 at 14:01 UTC | |
|