PropertyPath Constructor (Object)


The .NET API Reference documentation has a new home. Visit the .NET API Browser on to see the new experience.

Initializes a new instance of the PropertyPath class.

Namespace:   System.Windows
Assembly:  PresentationFramework (in PresentationFramework.dll)

Public Sub New (
	parameter As Object


Type: System.Object

A property path that either describes a path to a common language runtime (CLR) property, or a single dependency property.

This constructor has two completely different usages depending on whether it is being used for a source-mode property path for a binding, or for a target-mode single-step property path for a storyboard target.

If using this PropertyPath in source mode for a binding, parameter is a string representing a property name, or can be a string that describes a "step-through" path to the property in the CLR object model of the object that is being used as the source for a binding. For a binding property path, the character that identifies a "step" is a dot (.). Indexer references (including multiple indexers, and type differentiation) are also supported. For more details on the syntax of the string as specifically used by the Binding object, see Binding.Path. A property used as a binding source need not be a dependency property. If the binding updates two-way, the property referenced must be read-write. Also note that the binding target does have to be a dependency property. For details, see Data Binding Overview.

If using this PropertyPath in target mode for a single-step path for a storyboard target, parameter is generally provided as type DependencyProperty. You can also specify a string that is the Name. Either of these evaluate to the same result, because it is stored internally as a string. A provided DependencyProperty is converted to a string through DependencyPropertyConverter. The DependencyPropertyConverter supports a qualified naming format for dependency properties, so you can specify a typeName.propertyName qualified dependency property name string to the PropertyPath.PropertyPath constructor in code. The qualified path to the dependency property identifier is a different concept than a complex path. A complex-path PropertyPath should instead be created with the PropertyPath.PropertyPath constructor.

.NET Framework
Available since 3.0
Available since 2.0
Windows Phone Silverlight
Available since 7.0
Return to top