There is nothing built in, but it would be pretty easy.
Just take StackTrace :
// Create trace from exception var trace = new System.Diagnostics.StackTrace(exception); // or for current code location var trace = new System.Diagnostics.StackTrace(true);
Once you do this, simply move the frames of the stack and format them as desired.
There would be many ways to format this in HTML - it really depends on how you want it to look. The basic concept:
int frameCount = trace.Framecount; for (int i=0;i<frameCount;++i) { var frame = trace.GetFrame(i);
Reed copsey
source share