Hey everybody...
I have a hard time figuring out how to provide design-time integration for a List<string> with the StringCollectionEditor applied. When in the editor I can add the items, and everything is working beutifully, but I cannot find a way to notify the designer or the other properties to update with the changes in the string list.
If e.g. a ListBox is put on a form, the Items can be edited using an ListControlStringCollectionEditor, which is derived from StringCollectionEditor. After adding each item the UI is updated in the designer. I want to catch an event from adding an item or actully I would also be statisfied with the event of adding the entire list.
How can I connect with events (if any at all) from a UITypeEditor as the StringCollectionEditor?
The Editor, which I am using for my generic list...
Code:
[Editor("System.Windows.Forms.Design.StringCollectionEditor, System.Design",
"System.Drawing.Design.UITypeEditor, System.Drawing")]
I have tried the RefreshProperties attribute on the generic list property with no luck, and I think it is because the UI editor uses the Add method of the list, and therefore not the set-part, right?
Thanks a lot, Jacob.