How to make a dialog 'fail to open'?

Jurko Gospodnetić jurko_for_boost at mail.inet.hr
Sun Apr 22 09:45:57 PDT 2007


   Hi.

   I was wandering how to allow my dialog to 'fail to open'. It contains 
some code in its wxInitDialogEvent handler that could fail, in which 
case I do want to report an error and not allow the dialog to be open.

   The only way I found to do this so far is to throw an exception. Is 
this 'the only way' since wxWidgets attempts not to require exceptions?

   I tried skipping the event but could not find a way to skip the 
default event handler as well. As I saw from the code - if I could do 
that then the dialog would fail to open.

   Also... have not found any documentation on this...

   Using wxWidgets 2.8.3 on Windows XP. MSW build.

   Best regards,
     Jurko Gospodnetić





More information about the wx-users mailing list