|
-
January 16th, 2003, 08:38 AM
#1
Finding name of a method
Is there a way of finding the name of the method presently executing in order to include the method name in a debug printout ?
-
January 16th, 2003, 12:43 PM
#2
when you are in debug mode then put a break point where u are and go to debug of vs.net then under window you can see call stack or you could press
CTRL+ALT+C and print the stack trace.
or do you want the text file programatically. in that case your question seems to be too brief.
Paresh
-
January 17th, 2003, 02:09 AM
#3
I want to include trace/debug statements in deployed code
where the name of the method issuing the trace statements
is included in the statement
-
January 17th, 2003, 01:18 PM
#4
look in TRACE
public int Main(string[] args)
{
Trace.Listeners.Add(new TextWriterTraceListener(Console.Out));
Trace.AutoFlush = true;
Trace.Indent();
Trace.WriteLine("Entering Main");
Console.WriteLine("Hello World.");
Trace.WriteLine("Exiting Main");
Trace.Unindent();
return 0;
}
for more info or problem you could find
here
PareshGotDotNet
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
|