Ignore ASSERT Dialog?
-
I Want to ignore ASSERT Dialog on DEBUG mode using try ~ catch. How can i do it? :confused: help me pelase... And sorry for my little English. thanks..
You can't, they are different beasts. You can redefine the ASSERT macro, I suppose. Christian Graus - Microsoft MVP - C++
-
You can't, they are different beasts. You can redefine the ASSERT macro, I suppose. Christian Graus - Microsoft MVP - C++
I think you are confusing ASSERT (dialog which comes up due to statements like ASSERT(FALSE) ) and a crash dialog. ASSERT are more of a programmers tool to announce that something is wrong. If you dont want to have ASSERT coming up for an expression evaluating to be FALSE, then just remove them. Simple. And if you are interested in handling crashes gracefully, then you should have something like try { // Code resulting in probable crash. } catch(...) { }
-
I think you are confusing ASSERT (dialog which comes up due to statements like ASSERT(FALSE) ) and a crash dialog. ASSERT are more of a programmers tool to announce that something is wrong. If you dont want to have ASSERT coming up for an expression evaluating to be FALSE, then just remove them. Simple. And if you are interested in handling crashes gracefully, then you should have something like try { // Code resulting in probable crash. } catch(...) { }
Possibly a good answer, but you gave it to the wrong person. Christian Graus - Microsoft MVP - C++
-
I Want to ignore ASSERT Dialog on DEBUG mode using try ~ catch. How can i do it? :confused: help me pelase... And sorry for my little English. thanks..
Thinking about it furhter - I assume this means you get an ASSERT message in your code when you call an MFC or other function ? You should fix your code, not try to get rid of the ASSERT, which is simply warning you of a problem that will continue to exist. Christian Graus - Microsoft MVP - C++
-
Possibly a good answer, but you gave it to the wrong person. Christian Graus - Microsoft MVP - C++
>> wrong person Poor you. :laugh: I've seen this like 10 times already. Alex Korchemniy
-
I Want to ignore ASSERT Dialog on DEBUG mode using try ~ catch. How can i do it? :confused: help me pelase... And sorry for my little English. thanks..
thanks for answers. in fack, I have errors that can't know problem. so, I want to show error dialog that I made, instead of ASSERT message. How can catch ASSERT message in advance? This week is dead line of my project. help me, please... and sorry for my little English. Finally, have a nice day! Thanks...