net90_PropertyGridHelpers.Support_Support_GetPropertyInfo - dparvin/PropertyGridHelpers GitHub Wiki
Retrieves the PropertyInfo for the property described by the specified ITypeDescriptorContext.
public static PropertyInfo GetPropertyInfo(ITypeDescriptorContext context)
parameter | description |
---|---|
context | The type descriptor context containing metadata about the property, including its name and declaring component type. |
A PropertyInfo object representing the property described by context.
exception | condition |
---|---|
ArgumentNullException | Thrown when context is null . |
ArgumentException | Thrown when context does not contain a valid PropertyDescriptor. |
InvalidOperationException | Thrown when the property described by the context could not be found on the component type. |
Example usage:
var context = TypeDescriptorContext.Create(typeof(MyClass), "MyProperty");
PropertyInfo info = Support.GetPropertyInfo(context);
- class Support
- namespace PropertyGridHelpers.Support
- assembly PropertyGridHelpers