I want to get the stack trace but it is always empty?
try{ int a = 5, b = 0; int c = a/b; } catch(Exception &e){ ShowMessage("Exception: " + e.Message + "\nStackTrace:" + e.StackTrace); } Using C++ Builder XE2.
Edit: This code executes on TForm1::Button1Click.
Exceptionbeing thrown?ShowMessage("Exception: " + e.Message() + "\nStackTrace:" + e.StackTrace());?