FrameworkContentElement.GetBindingExpression Method (DependencyProperty)


Gets the BindingExpression for the specified property's binding.

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

Public Function GetBindingExpression (
	dp As DependencyProperty
) As BindingExpression


Type: System.Windows.DependencyProperty

The target DependencyProperty from which to get the binding.

Return Value

Type: System.Windows.Data.BindingExpression

Returns a BindingExpression if the target is data bound; otherwise, null.

The following example retrieves a binding by querying a property.

Dim binding As Binding = introParagraph.GetBindingExpression(FrameworkContentElement.TagProperty).ParentBinding

.NET Framework
Available since 3.0
Return to top