kgnickl has asked for the wisdom of the Perl Monks concerning the following question:

I have some code that uses Tk. It launches a word document then closes it. Problem is when it closes the word document the tk window falls back to where other apps are on top of it. I need the tk window to be the top most window after the word document closes. I tried focus, grab, etc... and I haven't found any way in windows to bring the tk window in front of all other windows so its in the users face. Thanks! Any advice or simple code I can add to do this?
use Tk; $mw = MainWindow->new(); $mw->geometry("400x170"); MainLoop; #Open document.... #Does some stuff.... #Close Document.... #Now I want the $mw to jump out in front of the users face on top of a +ll other windows whether they are tK perl related or lets say firefox +, internet explorer, excel, etc....

Replies are listed 'Best First'.
Re: Bring window to front in Tk GUI in Windows
by Anonymous Monk on May 06, 2011 at 00:50 UTC