Jump to content
Xtreme .Net Talk

ComboBox control in a column of DataGridView control in Visual Studio VB.NET 2005.


Recommended Posts

Posted
How can I place a comboxbox control and other controls in a column of datagridview control in vb.net ? If we can do so, then how can we access the values of these controls ?
  • 2 weeks later...
Posted

Hi,

 

To add combobox control, just use DataGridViewComboBoxColumn.

 

Add one column as DataGridViewComboBoxColumn in to your datagrid view control while adding columns to your control.. Set appropriate properties for the control before adding into columns collection. Refer MSDN documentaion for more information regarding that.

 

To retrieve values, just add code to retrieve values in the DatagridViewCellContentClick event. Then typecast the cell content to DataGridViewComboBoxColumn. Then u can access the properties from the instance you have just created...

 

Cheers...:)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...