本文介绍了CheckedListBox数据源C#3.5的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个窗口应用程序,我想显示checkedListBox.在这里,我想将CheckedListBox与DataSource绑定..
CheckedListBox,DataSource = dt;
CheckedListBox,DataMember = name;
CheckedListBox,ValueMember = Id;
我试过了.
但是我如何获得Valuemember?
请帮帮我.
非常感谢!
谢谢
Seema
Hi,
I have window application in this I want to show checkedListBox. Here I want to bind checkedlistbox with DataSource..
checkedlistbox,DataSource=dt;
checkedlistbox,DataMember=name;
checkedlistbox,ValueMember=Id;
I Tried it works.
But how can I get Valuemember?
Please help me.
Thank you very much!
Thank you
Seema
推荐答案
"DataSource Infrastructure. Gets or sets the data source for the control. This property is not relevant for this class."
并且:
And:
"Note You cannot bind data to a CheckedListBox. Use a ComboBox or a ListBox for this instead. For more information, see How to: Bind a Windows Forms ComboBox or ListBox Control to Data."
这篇关于CheckedListBox数据源C#3.5的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!