顯示具有 Get 標籤的文章。 顯示所有文章
顯示具有 Get 標籤的文章。 顯示所有文章

2017年7月27日 星期四

C# 找到 呼叫的Function的完整名稱

請參考以下的程式碼
MethodBase method = stackTrace.GetFrame(1).GetMethod();
string methodName = method.Name;
string className = method.ReflectedType.Name;
Console.WriteLine(className + "." + methodName);


How to find FULL name of calling method C#