I'm learning perl/tk programming - what tk binding can I use to call a function that does cleanup before closing the app when clicking on the X in the upper right?
I guess this would be the equivalent of the VB unload method.
Thanks for your help. I realize this is not a perl forum and I don't know TCL althought its not the only language that binds to Tk, but I think I figured out the way to do this in perl:
Code:
$mw->protocol('WM_DELETE_WINDOW' => sub { cleanup(); exit;} );
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.