PropertyBuilder::IsDefined Method (Type^, Boolean)
.NET Framework (current version)
Indicates whether one or more instance of attributeType is defined on this property.
Assembly: mscorlib (in mscorlib.dll)
Parameters
- attributeType
-
Type:
System::Type^
The Type object to which the custom attributes are applied.
- inherit
-
Type:
System::Boolean
Specifies whether to walk up this property's inheritance chain to find the custom attributes.
Return Value
Type: System::Booleantrue if one or more instance of attributeType is defined on this property; otherwise false.
| Exception | Condition |
|---|---|
| NotSupportedException | This method is not supported. |
Reflect on the property's parent type using Type.GetType or Assembly.GetType, retrieve the Reflection property object from the type, and call PropertyInfo.IsDefined.
.NET Framework
Available since 1.1
Silverlight
Available since 2.0
Available since 1.1
Silverlight
Available since 2.0
Show: