You should apply this attribute to a class with a custom designer to
indicate the nature of that designer. The design-time environment is
entitled to refuse to use your designer if you do not supply this
attribute.
The Category should be chosen from one of the
standard options (Component,
Form, or Generic ) if you wish
to integrate with the VS.NET designers. You could extend this with
your own custom categories if you are providing your own design-time
host.
public sealed class DesignerCategoryAttribute : Attribute {
// Public Constructors
public DesignerCategoryAttribute();
public DesignerCategoryAttribute(string category);
// Public Static Fields
public static readonly DesignerCategoryAttribute Component; // =System.ComponentModel.DesignerCategoryAttribute
public static readonly DesignerCategoryAttribute Default; // =System.ComponentModel.DesignerCategoryAttribute
public static readonly DesignerCategoryAttribute Form; // =System.ComponentModel.DesignerCategoryAttribute
public static readonly DesignerCategoryAttribute Generic; // =System.ComponentModel.DesignerCategoryAttribute
// Public Instance Properties
public string Category{get; }
public override object TypeId{get; }
// overrides Attribute
// Public Instance Methods
public override bool Equals(object obj); // overrides Attribute
public override int GetHashCode(); // overrides Attribute
public override bool IsDefaultAttribute(); // overrides Attribute
}