I have a combobox. And i have a datagridview.
i want when click combobox it drops datarows of datagridview down.
How can i do that ! thanks
Printable View
I have a combobox. And i have a datagridview.
i want when click combobox it drops datarows of datagridview down.
How can i do that ! thanks
you want a dropdown datagridview?
I assume that you mean that you want the values from one of the columns in the grid to be displayed in the ComboBox. Assuming that your data is bound, you can simply bind the same data to both the grid and the ComboBox. The specify which column to display in the ComboBox using the DisplayMember property:In that case 'myList' might be a DataTable or any other list you care to bind. "SomeColumn" can be the name of a DataColumn or the name of a property of the items in the list.vb.net Code:
Me.BindingSource1.DataSource = myList Me.DataGridView1.DataSource = Me.BindingSource1 Me.ComboBox1.DisplayMember = "SomeColumn" Me.ComboBox1.DataSource = Me.BindingSource1
Thanks Jm. But i am sorry. i mean i need all rows in datagridview or another dataset will drop down when i click combox.
It means not a column as you mention , i want all columns.
i am sure it is possible. because i saw that. but i dont know
thanks. :thumb:
It is possible, but you would either have to buy it, or make it. If you want to buy it I think ComponentOne had a similar control.
If you search for multicolumn combobox you will almost certainly find some results. It's been mentioned on this forum many times before. You might also try The Code Project as I'm sure there's at least one example there.
Thanks JM.
It is thing which i need.
Is that autocomplete combobox ?
Hi Nguyendangtruong.
Thanks for this subject. i need it too. :bigyello:
Thanks Jm.
i dont want to say this. but actually you are very wonderful.