How do I get full exception message in Java?
I am creating a Java Application. If there is a runtime exception, a JDialog with a JTextArea will pop up. I tried to make a runtime exception in my application, but the text area showing the exception message looks like this:
java.lang.ClassNotFoundException: com.app.Application
However, I want my text area to show something like:

Here is some part of my code surrounded by the try and catch:
String ex = e.toString();
this.addText(ex);
I've tried to use e.getLocalizedMessage() and e.getMessage(), but neither of these work.