Question

I have a PropertyGrid on my form, one of the properties I'm editing is a String List. I have implemented a UITypeEditor, so that when the user clicks the '...' button on that property, a new form appears.

This works really well, except that when the user saves the list, my property suddenly has two sub properties: Capacity and Count

My question is, how do I stop these sub properties being exposed?

Was it helpful?

Solution

You probably can sublass the List and set [Browsable(false)] attribute on Capacity and Count properties, which would prevent them to be shown in the PropertyGrid.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top