For C # UserControl on Windows Mobile (although please answer if you know it for full Windows ... this might work), how do you change what is displayed in the "Designer Properties" window for one of the public properties of the control. For example:
private Color blah = Color.Black; public Color Blah { get { return this.blah; } set { this.blah = value; } }
This is displayed for the control, but it belongs to the Miscellaneous category and has no description or default value. I tried using the settings in System.ComponentModel as "DesignerCategory", for example:
[DesignerCategory("Custom")]
But says that this is only valid for class declarations ... maybe swore that these were System.ComponentModel elements that I used before ...
Update:
@ John said:
DesignerCatogy is used to say class is a form, component, etc.
Try the following:
[Category ("Custom")]
Is there any specific namespace that I need to use to get them? I tried them for sure, and the compiler does not recognize them.
In .NETCF, everything that seems to me is accessible from System.ComponentModel:
DataObject, DataObjectMethod, DefaultValue, DesignerCategory, DesignTimeVisible, EditorBrowsable
The only thing he doesn't yell at is EditorBrowsable
c # windows-mobile user-controls
Adam haile
source share