I have a class that contains several public properties. One of those properties is a List containing instances of another class. It breaks down something like this:
namespace Irig106Library.Filters.PCM
{
[Description("Definition")]
public class MinorFrameFormatDefinition
{
[Description("Word Number")]
public int WordNumber { get; set; }
[Description("Number of Bits")]
public int NumberOfBits { get; set; }
}
public class MinorFrame
{
// ... other properties here
[Category("Format")]
[Description("Minor Frame Format Definitions")]
public List<MinorFrameFormatDefinition> MinorFrameFormatDefinitions { get; set; }
}
}
I have a PropertyGrid object which edits the Minor Frame object. It has a field containing a reference to the collection of MinorFrameFormatDefinition
objects. When I click on the button in this field to open the Collection Editor, and click the Add button, I get this:
How do I get the collection editor to label the objects with Definition
instead of Irig106Library.Filters.PCM.MinorFrameFormatDefinition
?