Creating a Battery Power Status Monitor in C#
Sometimes programs need to know the power status of a computer. An example is Windows Update, which often requires a computer to be running on mains power before updates are installed. This article explains how to read the power status and battery life.
Mimicking the VB.NET with clause in C#
In .NET everything is 100% object orientated; this could build up complex hierarchies and will produce some performance issues. This article will take a look at one of them and try to solve it in the best way possible.
Speed Test: Switch vs If-Else-If
The .NET framework and the C# language provide two methods for conditional processing where multiple discrete values can be selected from. The switch statement is less flexible than the if-else-if ladder but is generally considered to be more efficient.
Speed Testing and the Stopwatch Class
Software must operate at a speed that is acceptable to the end user. Often large improvements can be made by improving the speed of short-lived but heavily used routines. The speed of these can be accurately measured using the .NET 2.0 Stopwatch class.
Network World, an International Data Group publication, is the industry's only newsweekly shaping the future of network computing in the enterprise.
subscribe now