|
-
Feb 12th, 2004, 03:30 AM
#1
Thread Starter
Lively Member
Getting Function/Sub Name
Is there any way by which we can find out the name of the current Sub or Function that is executing ? I require this for error logging. I want to log in which Sub or Function did the error occured. And donot want to hardcode the name of the same everytime.
-
Feb 12th, 2004, 08:32 AM
#2
Reflection.MethodBase.GetCurrentMethod.Name
That should work.
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Feb 12th, 2004, 11:23 AM
#3
Don't suppose you know how to modify that one to grab the name of the current IDE procedure if you want to use this in a vs.net macro by any chance?
-
Feb 12th, 2004, 01:07 PM
#4
Nope, haven't done anything with macros so far.
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|