Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

DependencyPropertyDescriptor::IsReadOnly Property

 

Gets a value indicating whether this property is read-only.

Namespace:   System.ComponentModel
Assembly:  WindowsBase (in WindowsBase.dll)

public:
property bool IsReadOnly {
	virtual bool get() override;
}

Property Value

Type: System::Boolean

true if the property is read-only; otherwise, false.

This property relies on the underlying PropertyDescriptor.

Dependency properties are registered as read-only using particular method calls, and by convention the CLR wrapper properties that are the properties viewed by reflection and the descriptors must also be read-only. However, since this is a convention and not a requirement to compile, you might want to double check the dependency property identifier read-only state. To do this, get the identifier (DependencyProperty) value for this DependencyPropertyDescriptor and then check the value of ReadOnly. Note that the ReadOnly is on the identifier itself, not metadata.

.NET Framework
Available since 3.0
Return to top
Show:
© 2017 Microsoft