Tip #83: Did you know... You can get the name of the calling method from the stack using reflection?

Nearly every program needs a logger to log events, errors and exceptions. Sometimes it is also useful to log the name of the method that logged the event. The easiest way to do that is to make the log method take both the calling method name and event Read More...

Read the complete post at http://blogs.iis.net/webdevelopertips/archive/2009/06/23/tip-83-did-you-know-you-can-get-the-name-of-the-calling-method-from-the-stack-using-reflection.aspx

Published 06-24-2009 7:25 AM by The Official Microsoft IIS Site
Powered by Community Server (Non-Commercial Edition), by Telligent Systems