Method SetPropertyAttribute
SetPropertyAttribute(IPropertyGridItem, string, object?, PropertyGridItemValueFlags)
Sets an attribute for the property.
public virtual void SetPropertyAttribute(IPropertyGridItem prop, string attrName, object? value = null, PropertyGridItemValueFlags argFlags = PropertyGridItemValueFlags.DontRecurse)
Parameters
propIPropertyGridItemattrNamestringText identifier of attribute. See PropertyGridItemAttrId for the known attribute names.
valueobjectValue of attribute.
argFlagsPropertyGridItemValueFlagsOptional. Use Recurse to set the attribute to child properties recursively.
Remarks
Setting attribute's value to null will simply remove it from property's
set of attributes.