Getting current method:
System.Reflection.MethodBase.GetCurrentMethod()
Getting calling method:
System.Diagnostics.StackTrace st =
new System.Diagnostics.StackTrace(false);
System.Diagnostics.StackFrame sf =
st.GetFrame(1); // previous method
return sf.GetMethod();
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment