public class CallStack { public void Test() { try { this.A(); } catch( Exception e ) { Console.WriteLine( e.StackTrace ); } }
protected void A() { this.B(); }
protected void B() { try { this.C(); } catch( Exception /*e*/ ) { throw; } } protected void C() { this.D(); }
protected void D() { try { this.E(); } catch( Exception e ) { throw e; } }
protected void E() { this.Throw(); }
protected void Throw() { throw new Exception( "An Exception occurred" ); } }