Answer Posted / kirti
Yes. The Debug and Trace classes both have a Listeners property, which is a collection of sinks that receive the tracing that you send via Debug.WriteLine and Trace.WriteLine respectively. By default the Listeners collection contains a single sink, which is an
instance of the DefaultTraceListener class. This sends output to the Win32 OutputDebugString() function and also the System.Diagnostics.Debugger.Log() method. This is useful when debugging, but if you're trying to trace a problem at a customer site, redirecting the output to a file is more appropriate. Fortunately, the TextWriterTraceListener class is provided for this purpose.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is Layout in ASP.Net MVC?
What is routeconfig.cs in mvc 4?
What is the use of the default route {resource}.axd/{*pathinfo} ?
What is the meaning of unobtrusive javascript? Explain us by any practical example.
What is the need of Action Filters in ASP.Net MVC
what is lazy loading in entity framework?
Which is the default http method for an action method?
What are the 3 main components of an asp.net mvc application?
sql related question (outer join, left, right etc) array vs hashtable CRL sqldatareader vs dataset what is WPF, WCF, compare to WinForms Webservices Asp.net MVC vs WebForms?
What is meant by domain model?
What is orm entity framework?
What is net framework 3.0 ?
Is .net framework backwards compatible?
What are actions in mvc?
why DotNetFramework is included in building a software