What?s the difference between the Debug class and Trace class?

Answer Posted / kabita

Debug Class provides a set of methods and properties that
help debug your code. If you use methods in the Debug class
to print debugging information and check your logic with
assertions, you can make your code more robust without
impacting the performance and code size of your shipping
product. In Visual Studio 2005 projects, creating a debug
build enables Debug.


You can use the properties and methods in the Trace class
to instrument release builds. Instrumentation allows you to
monitor the health of your application running in real-life
settings. Tracing helps you isolate problems and fix them
without disturbing a running system.
In Visual Studio 2005 projects, Trace is enabled by default
for both release and debug builds, so code is generated for
all trace methods in both release and debug builds.
Therefore, you can use Trace to instrument release builds.

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why do I get a syntax error when trying to declare a variable called checked?

781


how to insert the data from the grid view to database table though button click.pls send the answer to mail id suri1319@gmail.com

1706


Explain the difference between const and static read-only?

710


What language do desktop applications use?

688


How can I produce an assembly?

816


What are virtual destructors?

720


What is the purpose of a console table?

650


Can class inherit from struct c#?

723


What is the name of c# compiler?

843


Why do we need to serialize data?

667


What are callback methods in c#?

692


What is a multi line comment?

739


what is collections in .net? why we use?

1892


In .NET how can you solve the DLL Hell problem?

867


What are verbatim strings in c#?

679