Google


   


You are here: CodeIdol.com > C# > C# Cookbook, 2nd Edition > Diagnostics

SAVE
Digg
Shown on del.icio.us del.icio.us
See Whos Talking About This on Technorati Technorati
I've Reddit reddit

C# Cookbook, 2nd Edition



Problem: Mysterious bugs often appear at the client's site, even after the application is thoroughly tested. Most of the time these bugs are difficult, if not impossible, to reproduce on your development machine. Knowing this, you want an applicatio...



Problem: Your application consists of multiple components. You need, at specific times, to turn on debug/trace output for a select few components, while leaving all other debug/trace output turned off. In addition, you need control over the type and...



Problem: The BooleanSwitch and traceSwitch classes defined in the FCL may not always have the required flexibility or fine-grained control that you need. You want to create a switch class that provides more control and flexibility. For example, you ...



Problem: Specific blocks of code will be used only in a certain build configuration for your application. These blocks of code should not be compiled into other builds of the application. You need a way to conditionally compile specific blocks of co...



Problem: You need to watch one or more processes to determine whether the user interface has stopped responding to the system. This functionality is similar to the column in the TaskManager that displays the text Responding or Not Responding, depend...



Problem: You need to add the ability for your application to log events that occur in your application, such as startup, shutdown, critical errors, and even security breaches. Along with reading and writing to a log, you need the ability to create, ...



Problem: Custom event logs are created with a default maximum size of 512K. For some applications, this default may be too small or even too large. You need a way of programmatically modifying this size. If you are a system administrator, you might ...



Problem: Your application might have added many entries to the event log. To perform an analysis of how the application operated, how many errors were encountered, and so on, you need to be able to perform a search through all of the entries in an e...



Problem: You may have multiple applications that write to a single event log. For each of these applications, you want a monitoring application to watch for one or more specific log entries to be written to the event log. For example, you might want...



Problem: You need to determine which sources are attached to a particular event log before the log is examined and/or deleted. A source is a component or application that has registered itself to a particular event log as a source of events. So...



Problem: You need to use a performance counter to trackapplication-specific information. The simpler performance counters find, for example, the change in a counter value between successive samplings or just count the number of times an action occur...



Problem: You need to use some of the more advanced performance counters to accurately track information about your application. The performance counters exist as two counters used together. The first counter is the main counter, which is divided by ...



Problem: You have an object that contains complex tracing/debugging code. In fact, there is so much tracing/debugging code that to turn it all on would create an extremely large amount of output. You want to be able to generate objects at runtime th...



Problem: You need to be able to capture standard output for a process you are launching. Solution: Use the RedirectStandardOutput property of the Process.StartInfo class to capture the output from the process. By redirecting the standard outpu...



Problem: You have a set of classes that are used in your application. You would like to see at a glance in the debugger what a particular instance of the class holds. The default debugger display doesn't show any useful information for your class to...



Problem: You want to know about the current settings for the appdomain your code is executing in to help in debugging various issues with assembly loading, authorization issues, and startup problems. Solution: Examine the properties of the app...



Problem: You want a specific program to run at a higher priority than most of the other processes on the machine to help it complete a time-critical task. Solution: Use the ProcessStartInfo and Process classes to launch the program and then ad...



Problem: You want a way to easily gather information about the environment your program is running under to assist in troubleshooting customer issues. Solution: Write a utility function that can gather this information for the process using th...


SAVE
Digg
Shown on del.icio.us del.icio.us
See Whos Talking About This on Technorati Technorati
I've Reddit reddit

You are here: CodeIdol.com > C# > C# Cookbook, 2nd Edition > Diagnostics


ADBRITE ads links
   
Related tags







Popular Categories
Unix books and guides

AJAX popular information
C# language guides
Windows books and cookbooks

.......








Business Key Top Sites

be number one
rate your site




    С 2009 года мы стали переводить структура сайта на различные языки. Сайт теперь будет содержать книги не только на английском языке, но также и на других европейских языках, в том числе и на Русском языке.

    Русский Polski Francais Deutsch
    support sitemap terms

© CodeIdol Labs, 2007 - 2009