Wrox Programmer Forums
|
Visual Basic 2010 General Discussion For any discussions about Visual Basic 2010 topics which aren't related to a specific Wrox book
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Visual Basic 2010 General Discussion section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old June 19th, 2010, 03:51 PM
Authorized User
 
Join Date: May 2010
Posts: 70
Thanks: 4
Thanked 6 Times in 6 Posts
Send a message via Yahoo to GeneBuchite
Cool Combo Box Help

Does anyone know how to change the textbox style in a class generated dataGridView object to a ComboBox.
I know how to change a textbox in a Databound DataGridView to a combobox. but I dont know how to change TextBox to ComboBox In a class generated DataGridView.
 
Old June 28th, 2010, 12:02 PM
Registered User
 
Join Date: Jun 2006
Posts: 5
Thanks: 1
Thanked 1 Time in 1 Post
Default

If I understand you, class generated means you want to generate the form with the datagridview by code. Whichever, take a peep into the code generated by the designer when you drop a datagridview onto the form and after configuring the datagridview datasource (preferred datasource is a BindingSource just in case), then configure one of the columns by changing the default GridViewTexBoxColumnType to ComboBoxColumnType. Remember, you'll need to set the DisplayMember and ValueMember. Study the generated code in the WinForm e.g Form1.designer.vb.
The Following User Says Thank You to taofeeklasisi For This Useful Post:
GeneBuchite (June 29th, 2010)
 
Old June 29th, 2010, 07:54 AM
Authorized User
 
Join Date: May 2010
Posts: 70
Thanks: 4
Thanked 6 Times in 6 Posts
Send a message via Yahoo to GeneBuchite
Default

Thak you. I'll See what I can find this way.





Similar Threads
Thread Thread Starter Forum Replies Last Post
Populate a text box from a combo box value dnf999 Access VBA 7 February 6th, 2012 02:24 PM
Combo box to display items from parent combo box Gini Visual Studio 2008 0 June 18th, 2008 12:30 AM
Count in combo box(display results in text box) mboyisis Access 4 April 4th, 2008 07:08 AM
Combo box choice creating filtered combo box stevensj5 Access 11 September 13th, 2007 11:33 AM
Populate List Box by Combo Box Selection mmcdonal Access 2 June 15th, 2004 12:08 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.