Hi,
this one is easy (I hope):
1. Create an editor for such a property, and derive from UITypeEditor
2. Override GetEditStyle() and return UITypeEditorEditStyle.Dropdown I think
this should work.
3. Override EditValue() to dropdown a Listbox with the two strings, true and
false.
4. Override GetPaintValueSupported() and return true to indicate that you'd
like to paint a little checkbox.
5. Override PaintValue() to to the painting in the value cell of the
property. The Drawing namespace has static methods that paints buttons, I
think there should be one that paints a checkbox image. The PaintValue()
arguments provide everything needed for painting.
6. Decorate your bool property with the [Editor( typeof( yourEditorClass ),
typeof( UITypeEditor ))]. This associates the editor with your property.
There is a tutorial in the msdn documents, entitled "Enhancing Design-Time
Support" which has a link to a working sample.
HTH, ulrich
> Hi all,
>
[quoted text clipped - 5 lines]
>
> Yongkee