多列组合框 [英] THE Multi Column ComboBox
本文介绍了多列组合框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
Multi column comboBox是一个口语很好的控件,很多人都希望b / b
,很多人都是自己构建的。我测试了很多,但没有一个
真的是我想要的。
但是有谁知道我在哪里可以找到最好的多列组合框?一个
支持很多列,可以获得所选项目的每个
列中的值,添加数据源等...
它应该是免费的,如果可能的话还有源代码(在VB.NET中)。
非常感谢提前,
Pieter
Hi,
The Multi column comboBox is a well spoken control, that a lot of people
desire, and a lot of people buildtheir own. I tested a lot of them, but none
really was what i wanted to have.
But does anybody knows where I can find the best Multi column combobox? One
that supports a lot of columns, possiblities to get the values in each
column for the selected item, adding a DataSource etc...
It should be free, and if possible with the source code (in VB.NET).
Thanks a lot in advance,
Pieter
推荐答案
Pieter,
什么是多列组合框。对我来说,它听起来像是一个组合框中更多的组合框架。不过可能你的意思是
呢?
Cor
Pieter,
What is for you a multicolumn combobox. For me it sounds as more comboboxes
side by side in a group box. However probably you mean something else with
it?
Cor
Hi Cor,
我的意思是:
1个组合框,但在下拉列表中有超过1列(而不是1
就像有在正常的组合框上。
Pieter
" Cor Ligthert" <无************ @ planet.nl>在消息中写道
news:uX ************** @ TK2MSFTNGP12.phx.gbl ...
Hi Cor,
I mean:
1 combobox, but with in the dropdown-list more than 1 columns (and not 1
like there is on the normal combobox).
Pieter
"Cor Ligthert" <no************@planet.nl> wrote in message
news:uX**************@TK2MSFTNGP12.phx.gbl...
Pieter,>
什么是多列组合框。对我来说,它听起来像一个组合框中并排更多
组合框。不过你可能意味着什么呢?
Cor
Pieter,
What is for you a multicolumn combobox. For me it sounds as more comboboxes side by side in a group box. However probably you mean something else with
it?
Cor
Pieter,>
我仍然不知道你的意思,你有没有试过这个,尝试一下并告诉
而不是它的好坏。
\\ []需要在表格上并排放置3个组合框并粘贴在此代码中。
Private Sub Form1_Load(ByVal sender _
As System.Object,ByVal e As System.EventArgs)处理MyBase.Load
Dim dt As New DataTable
dt.Columns.Add(" a" )
dt.Columns.Add(" b")
dt.Columns.Add(" c")
dt.LoadDataRow (New Object(){" Pieter"," Belgie"," Lambik"},True)
dt.LoadDataRow(New Object(){" Cor"," Holland" ,Heineken},True)
dt.LoadDataRow(New Object(){" Rinze"," Zeeland"," Stella"},True)
dt .DefaultView.Sort =" b"
ComboBox1.DataSource = dt
ComboBox1.DisplayMember =" a"
ComboBox1.ValueMember = " b"
ComboBox2.DataSource = dt
ComboBox2.DisplayMember =" b"
ComboBox2.ValueMember =" c"
ComboBox3.DataSource = dt
ComboBox3.DisplayMember =" c"
ComboBox3.ValueMember =" a"
End Sub
///
我希望这会有所帮助,
Cor
Pieter,
I still don''t know what you mean, did you ever tried this, try it and tell
than what is good or wrong on it.
\\\needs 3 comboboxes side by side on a form and pasting in this code.
Private Sub Form1_Load(ByVal sender _
As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim dt As New DataTable
dt.Columns.Add("a")
dt.Columns.Add("b")
dt.Columns.Add("c")
dt.LoadDataRow(New Object() {"Pieter", "Belgie", "Lambik"}, True)
dt.LoadDataRow(New Object() {"Cor", "Holland", "Heineken"}, True)
dt.LoadDataRow(New Object() {"Rinze", "Zeeland", "Stella"}, True)
dt.DefaultView.Sort = "b"
ComboBox1.DataSource = dt
ComboBox1.DisplayMember = "a"
ComboBox1.ValueMember = "b"
ComboBox2.DataSource = dt
ComboBox2.DisplayMember = "b"
ComboBox2.ValueMember = "c"
ComboBox3.DataSource = dt
ComboBox3.DisplayMember = "c"
ComboBox3.ValueMember = "a"
End Sub
///
I hope this helps,
Cor
这篇关于多列组合框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文