Returns the current effective value of a dependency property on this instance of a DependencyObject.
public:
System::Object ^ GetValue(System::Windows::DependencyProperty ^ dp);
public object GetValue(System.Windows.DependencyProperty dp);
member this.GetValue : System.Windows.DependencyProperty -> obj
Public Function GetValue (dp As DependencyProperty) As Object
Parameters Returns
Returns the current effective value.
ExceptionsThe specified dp
or its value was invalid, or the specified dp
does not exist.
The effective value is the value of the property that is returned by the property system to any caller that is requesting the value. The effective value is the result of the property system having evaluated all the possible inputs that participate in the property system value precedence. This includes coercion and animation. For more information, see Dependency Property Value Precedence.
This method will never return UnsetValue. The UnsetValue is a sentinel value for the property system that is used in various capacities internally and occasionally also exposed through coercion callbacks.
If you are not sure what the property's type should be, you can query the identifier of the requested dependency property to determine whether there is a more specific PropertyType that the return value can be converted to.
See alsoCollaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide. In this articleWas this page helpful?
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4