public static string GetCurrentMethod() { string trace = ""; StackTrace st = new StackTrace(); foreach(StackFrame frame in st.GetFrames()) { trace += " " + frame.GetMethod().Name; } return trace; }