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

What is the difference between static and constant variables?

537


What is difference between c and c sharp?

454


What is concrete class in c# with example?

464


What is difference between struct and class in c#?

465


What is dll in vb.net?

480






What are the uses of namespaces?

602


What is the difference between virtual and override in c#?

475


What is enumerable in c#?

472


Is c# a technology?

488


What is cosole application?

570


How to implement an object pool in c#.net.

546


What are the advantages of properties in c#?

551


What is readline library?

502


What are the boolean data types in c#?

510


What is typeof undefined?

505