exception handling
-
I do not know a way to get all exceptions. try { } catch(CException *e){} is not working for all exceptions. If I put catch(...) it is ok but I cannot get the error message this way. Do you know what I can put in the catch () so that I can handle all exceptions having their messages. Thank you!
-
I do not know a way to get all exceptions. try { } catch(CException *e){} is not working for all exceptions. If I put catch(...) it is ok but I cannot get the error message this way. Do you know what I can put in the catch () so that I can handle all exceptions having their messages. Thank you!
In order to catch everything, you need to look at the docs for the function which is throwing the exception and then add a catch statement specific for that.
try { } catch(CException *e) { } catch(LPTSTR szErr) { } catch(...) { }
Waldermort
-
In order to catch everything, you need to look at the docs for the function which is throwing the exception and then add a catch statement specific for that.
try { } catch(CException *e) { } catch(LPTSTR szErr) { } catch(...) { }
Waldermort
Have u tried using "try-finally-statements" -Sachin
-
I do not know a way to get all exceptions. try { } catch(CException *e){} is not working for all exceptions. If I put catch(...) it is ok but I cannot get the error message this way. Do you know what I can put in the catch () so that I can handle all exceptions having their messages. Thank you!
Im not sure but I think some times ago I saw a code on the http://www.koders.com about get exceptions see this site.
-
Have u tried using "try-finally-statements" -Sachin
Exactly how does that get the text of the exception being thrown?
"A good athlete is the result of a good and worthy opponent." - David Crow
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne