且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

WPF:多个控件更改绑定属性

更新时间:2022-06-22 02:41:21

您不能样式或模板做到这一点,因为绑定是不是 FrameworkElement的。但是,你的一个类继承的想法绑定应该可以正常工作,我已经做了相同的前一个类似的问题

You can't do it with a style or template, since a binding is not a FrameworkElement. But your idea of a class inheriting Binding should work fine, I've done the same before for a similar problem