How do I reset a DependencyProperty back to it's default value in XAML
问题 I'm implementing a user-adjustable Effect using sliders and I have a reset button beside the slider. The idea is to allow the user to reset back to the default value of the Effect 's property as specified in metadata. I think it might be trivial to do that in XAML. 回答1: Dependency properties don't really have default values. If a dependency property doesn't have a local value, it will obtain its value either through value inheritance or through coercion, depending on how the property has been