[perl-win32-gui-users] Catching die() before Win32::GUI

2005-06-08 Thread Robinson
[docs] Finally, you should note that events are really evaluated (as if they were called with eval()), so that errors are trapped, and a message box is shown. This box reports the offending event name on the title bar, the error message in its body and has OK and Cancel buttons. If you press OK,

Re: [win32gui] [perl-win32-gui-users] Catching die() before Win32::GUI

2005-06-08 Thread Robert May
Can you catch the 'die' by putting the offending call in an eval block (perldoc -f eval). Regards, Rob. #!perl use strict; use warnings; use Win32::GUI; my $mw = Win32::GUI::Window-new( -title = Cheating death, -pos = [100,100], -size = [100,100], ); $mw-AddButton( -text = Click me!,