本文介绍了WPF绑定复选框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

HI,

我完全是WPF的初学者.我正在尝试使用复选框绑定进行一些操作.但是,正如我在下面解释的那样,我被卡在这里了.请有人帮我解决这个问题.

I'm completely a beginner in WPF.I'm trying out few things with checkbox binding .however i got stuck here as i explained below.Someone please help me out on this.

我创建了一个Genericcontrol,在xaml.cs文件[labels,checkboxes]中添加了所需的控件[自定义代码].从ViewModel加载了标签上下文和checkboxes [显示名称]上下文,还设置了复选框绑定属性[ 相应的视图模型],然后将复选框与该事件中的已选中事件相关联.

I have created a Genericcontrol, where the required controls[custom code] are added in xaml.cs file [labels , checkboxes].loaded the  label context and checkboxes[display names] context from a ViewModel, also set the checkbox binding properties[to the corresponding view model] and tied the checkbox to a checked event in that .

现在,每当我选中复选框时,都会选择我已加载的所有复选框.

Now whenever i am checking the checkbox , all the checkboxes i have loaded are getting selected.

我不知道该如何处理.请帮帮我.谢谢.

I dont know how to handle this .Please help me out .Thank you .

推荐答案


这篇关于WPF绑定复选框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-05 23:28