article

Using alternate descriptions for enumeration members

Enums are useful language features. But what happens when you want to display a string version of an enum member rather than just casting the member to a string? You could manually create a switch statement for conversion, and periodically update such functions when extending the source enum. Or you could use the power of reflection and attributes to do it automatically.

avatar
Richard Moss
article

Creating a custom TypeConverter part 2 - Instance descriptors, expandable properties and standard values

This article describes extending a custom `TypeConverter` created previously to support better code generation, expandable properties, and dropdown lists containing standard values.

avatar
Richard Moss
article

Creating a custom TypeConverter part 1 - getting started

Type converters allow classes to be edited via designers such as the `PropertyGrid`. This article details how to create a simple type converter to and from a `string` for use with a `PropertyGrid` control.

avatar
Richard Moss