I’d like to present my exception to my advanced users in a nice HTML way.
Is there any convenient way (using library, or small amounts of code) to convert the details of an System.Exception (and inner exceptions) into nice presentation HTML?
I’ve tried looking at the ELMAH code base but it seems to use the older HTMLWriter for building the HTML document.
I was hoping to find something a bit simpler.
Any help is greatly appreciated.
The best way to present Exceptions to users (even advanced users) is to not present them at all. Simply present the user with a well formatted error page explaining that something went wrong, you logged the error, and you’ll look in to it.
There are two problems with giving users details about the Exception that occurred:
Reveals details about the implementation of your software which could, theoretically, be exploited by malicious users.
Users (even Advanced Users) can’t do anything about the Exception when it happens. They’re still just users. Why give somebody details about a problem that they can’t do anything about?