datagridview add a combobox to a single cell, not a whole column

G

Guest

I would like to have a DataGridView that has a column in it that contains a
combobox only on certain rows. I have searched the web and the only solution
I have found is to create a custom DataGridView control. There must be an
easier way to do this. Any suggestions?


-- Mikeq
 
B

Bill Joyce [MS]

You can just set the cell reference:
myGrid[0, 0] = new DataGridViewComboBoxCell();
 
G

Guest

Bill, Thanks a lot, I spent a whole day looking for the answer on the web and
in the documentation. Your solution does exactly what I need to do.

Thanks again

-- Mikeq


Bill Joyce said:
You can just set the cell reference:
myGrid[0, 0] = new DataGridViewComboBoxCell();
I would like to have a DataGridView that has a column in it that contains a
combobox only on certain rows. I have searched the web and the only solution
I have found is to create a custom DataGridView control. There must be an
easier way to do this. Any suggestions?


-- Mikeq
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top