in reply to Windows Exit from Dialog Box in Perl/Tk

I've worked with Perl/Tk using ActiveState 5.6 and 5.8 and have had no problems using the "X" to close windows. If you want to capture that, it's the "destroy" event, so for a mainWindow $mw, use  $mw->OnDestroy( \&this_sub );

Maybe you're code is expecting something to be returned and when it's not it prevents the destroy call. It would really help us to help you if you posted some of the relevant code. . .

- - arden.

Replies are listed 'Best First'.
Re^2: Windows Exit from Dialog Box in Perl/Tk
by antioch (Sexton) on Jun 04, 2004 at 15:57 UTC
    Hmm.. I know how to destroy a window with a button and all but yeah I can't close it with that "X". Heres some of the relevant code which is really just a dialog box..
    my $dialog_comingsoon = $main_window->DialogBox( -title => "COMING SOON"); $dialog_comingsoon->Label(-text=>'Patience.')->pack; $dialog_comingsoon->Label(-text=>'This feature will be act + ive in the next release.')->pack; $dialog_comingsoon->Label(-text=>'Thank You.')->pack;
    Heres also an example picture of the dialog box:

    http://www.angelfire.com/linux/penguinfood/dialogbox.jpg