cornercorner
FeaturesPluginsDocs & SupportCommunityPartners

DevFaqUnexpectedExceptionDialog

How can I suppress the Unexpected Exception dialog?

If your code generates an uncaught exception at runtime, NetBeans will display a dialog box which can show the details of that exception to the user. This is a welcome alternative to simply crashing the application, and provided you have written solid code, your user should never see this dialog anyway.

But it is impossible to handle every possible exception or error, and some developers might wish to simply suppress this dialog so that the application neither crashes nor alerts the user that an uncaught exception/error was thrown. You can do this by setting a system property at runtime named netbeans.exception.report.min.level. The exact value of this property will depend on certain factors such as whether or not assertions are enabled, but using a very high value such as 99999 should prevent the dialog from ever being shown.