Code::Blocks Forums
User forums => Help => Topic started by: HealingAura on November 28, 2006, 11:36:05 pm
-
Hello,
I am trying to use Exceptions Handling in my C++ program but instead I keep getting this:
"This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information."
Instead of getting the right error text printed, this text above shows up and the program quits.
Did I forgot to enable something? Something tells me it's not supposed to happen :?
-
It should work (if your code is right), and you haven't passed -fno-exceptions to GCC (assuming GCC).
C++ exception handling works fine for me. BTW this isn't a programming forum. ;)
-
I use GCC compiler but I don't see this -fno-exceptions. Any idea why I get this message?
The code looks like this:
int FunctionName()
{....
switch (num)
{ ..... default: throw "invalid number"; }
... }
int main()
{ ...
try { ... FunctionName(); ... }
catch(char *msg) { cout<<msg<<endl; }
... }
-
BTW this is a programming forum. ;)
???
-
BTW this is a programming forum. ;)
???
:lol: :lol: :lol: :oops:
isn't :P
-
BTW this is a programming forum. ;)
???
:lol: :lol: :lol: :oops:
isn't :P
Am I in the wrong forum? :oops:
-
Am I in the wrong forum? :oops:
Sorry about that.
Programming questions on this forum should be related to the *use* of CodeBlocks. Not general questions concerning programming.