|Perl: the Markov chain saw|
Re: Win32 GUI Window Problemby jplindstrom (Monsignor)
|on Jan 28, 2009 at 13:43 UTC||Need Help??|
Don't call Win32::GUI::Dialog many times.
Create the windows, populate them, show them, and then call Win32::GUI::Dialog once. This is the main loop which runs until any event handler returns -1.
As it is now, the code will put up a window, wait for you to close it, then look at the next line.
Personally, I'd create a single window and add rows to a text area or something like that.
(If in the future you want to do something like tail -f you need to poll file handles IO::Select. Set up a timer to check if there's anything to read.)
I think you need to read an intro to Win32::GUI, especially how event handlers work and how window names relate to them (this is a bit clunky in Win32::GUI).
There's a mailing list which may be able to provide better answers: win32-gui-users
There's a half finished tutorial which covers the basics about gui programming with Win32::GUI.