Free Developer Tools

4 Comments »

Following are some simple but useful FREE tools for software developers. Each tool is freely distributable and includes the original C# source code so you can modify the tool to your needs. These tools are not supported. Enjoy!

Color Gadget

Select a .NET KnownColor or other color, copy RGB and hex values to the clipboard.

Free Download

Guid Generator

Generate a new globally-unique ID and copy it to the clipboard.

Free Download

Hex Converter

Quickly convert between hex and decimal numbers.

Free Download

Shortcut Replace

Search/replace the path and working directory in a collection of shortcut (.lnk) files.

Free Download

Visual Studio Toolbox Installer

Console program that installs/removes tabs and custom controls and components in the Visual Studio .NET Toolbox.

Free Download

Window Watcher

Shows the form and client bounds of the active window.

Free Download

C# ?? Operator

4 Comments »

C# 2.0 introduced the ?? or null coalescing operator. The ?? operator has two operands and can be used in an expression as follows:

x = y ?? z;

Read the rest of this entry »

Visual Studio 2008 and .NET 3.5 Released

No Comments »

Microsoft has released Visual Studio 2008 and .NET Framework v3.5. These upgrades enable .NET software developers to rapidly create more secure, manageable, and reliable applications and take advantage of new features found in Windows Vista and Microsoft Office 2007.

Read the rest of this entry »

Convert Between Synchronous and Asynchronous

6 Comments »

When a program calls a synchronous function, the program halts and waits for the function to finish executing. When a program calls an asynchronous function, the program does not wait and continues to execute while the asynchronous function executes in the background.

By default, C# methods are synchronous. External functions that can take a long time to execute–such as interprocess communications (IPC) and database queries–are typically asynchronous. However, there may be instances where you need to make a synchronous function asynchronous and vice-versa.

Read the rest of this entry »

C# Stable Sort

9 Comments »

A sort is stable if the original order of equal elements is preserved. An unstable sort does not guarantee that equal elements will appear in their original order after sorting.

The Sort methods used by the .NET collections are unstable. These sort methods, which include System.Array.Sort and System.Collections.Generic.List<T>.Sort, use the QuickSort algorithm, which is relatively fast but in this case, unstable. However, there may be instances where you require a stable sort, so a custom solution is required.
Read the rest of this entry »