develooper Front page | perl.beginners | Postings from January 2002

A tk question

Thread Next
From:
Murzc
Date:
January 7, 2002 14:45
Subject:
A tk question
Message ID:
199.c02ca1.296b7f19@aol.com

I have a TK issue.

This code creates the initial TK box.

>>  use vars qw/$TOP/;

>>  $TOP = Tk::MainWindow->new;

>>  $TOP->title('blah blah');
>>  $TOP->configure(-background => lc('PeachPuff1'));
etc.(a lot more code)

When the user clicks the button of his choice, the TK box disappears into the task bar.
When the user clicks the task bar on the program's name,
a window of a DOS screen pops up and asks the user 
"Enter Perl Script to execute."

The code is below. 


>>  $TOP->iconify;
>>  $TOP->withdraw;

>>  print "\nEnter Perl Script to execute: ";

>>  $pgm = <STDIN>;
>>  chomp($pgm);

etc.


The question we are having.
Why do it in 2 steps. 1: Click the TK button.  2: Clikc the Task bar.
Why not do it one step if possible?
Can the Dos screen pop up right away after the button is clicked?   

If you need more of the code let me know.

Thank you.



Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About