Slider in WPF Dependency Property
I'm trying to set the Value of the Slider to 1.0 but whe开发者_开发知识库n in debugger, I can see that after the assignment like:
surfaceSlider.Value = 1.0;
the value stays at the current value (0.0).
Any ideas why I can't set that dependency property?
WPF Slider Value property is dependency property, this will accept the values.
I think you are creating a custom control with a dependency property named "Value". Make sure your setter property is public and OwnerType is your class.
精彩评论