c# - Printing the stack trace only when an exception thrown -


i developing own automated bug reporting system project, want know is there way stack trace of program when exception thrown, know how full stack trace file in case need catch stack trace exception (stack trace relevant exception), please direct me. if there code sample, grate!

code used stack trace below

            stacktrace st = new stacktrace();             richtextbox1.text = st.tostring(); 

thanx in adavance! using below technologies in project c#, .net 4.0.

the exception object has stacktrace property can use stack trace exception when caught.

try {    // code } catch (exception ex) {    richtextbox1.text = ex.stacktrace; } 

Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

android - Keyboard hides my half of edit-text and button below it even in scroll view -

css - Make div keyboard-scrollable in jQuery Mobile? -