I tried to catch exception in my wxWidgets application but it didn't succeed: int MyApp::MainLoop() { int retour; try { retour=wxApp::MainLoop(); } catch(const CErreur& e) { wxLogError("Exception"); } catch(...) { wxLogError("Defaut"); } return retour; }