Click here to Skip to main content
15,911,531 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralString to Datagridviewcell Conversion Pin
VB 8.013-Dec-07 1:09
VB 8.013-Dec-07 1:09 
GeneralRe: String to Datagridviewcell Conversion Pin
Dave Kreskowiak13-Dec-07 1:48
mveDave Kreskowiak13-Dec-07 1:48 
GeneralRe: String to Datagridviewcell Conversion Pin
VB 8.014-Dec-07 0:42
VB 8.014-Dec-07 0:42 
GeneralRe: String to Datagridviewcell Conversion Pin
Dave Kreskowiak14-Dec-07 0:48
mveDave Kreskowiak14-Dec-07 0:48 
GeneralRe: String to Datagridviewcell Conversion Pin
VB 8.016-Dec-07 21:43
VB 8.016-Dec-07 21:43 
GeneralRe: String to Datagridviewcell Conversion Pin
Dave Kreskowiak17-Dec-07 1:41
mveDave Kreskowiak17-Dec-07 1:41 
QuestionHow to Update Binded Combobox value ? Pin
rashadaliarshad12-Dec-07 23:29
rashadaliarshad12-Dec-07 23:29 
GeneralRe: How to Update Binded Combobox value ? Pin
Dave Kreskowiak13-Dec-07 4:15
mveDave Kreskowiak13-Dec-07 4:15 
OK. There's a few things you have to do.

First, you need a second BindingSource and set it's DataSource and DataMember properties to the table that's going to supply the ID's and Text for the ComboBox to show. It helps greatly if the DataSet you're using has both the table that you're already showing and the table that's supplying the data for the ComboBox. There's normally a one-to-many relationship between these two tables.

The DataSource property of the ComboBox needs to be set to the BindingSource you just created. Also set it's DisplayMember to the field that's supplying the Text the user gets to see in the Combo and set the ValueMember property to the field that's supplying the ID's for those text items.

Then, create a new Binding object and add it to the DataBindings property of the ComboBox. This binding needs to bind the SelectedValue property of the ComboBox to the original BindingSource you already have on the form and the name of the field in that bindingsource that's going to hold the value selected in the ComboBox.


A guide to posting questions on CodeProject[^]



Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic
     2006, 2007




AnswerRe: How to Update Binded Combobox value ? Pin
rashadaliarshad13-Dec-07 20:57
rashadaliarshad13-Dec-07 20:57 
GeneralRAS - Creation of a VPN connnection Pin
Xavier Laurent12-Dec-07 23:24
Xavier Laurent12-Dec-07 23:24 
GeneralRe: RAS - Creation of a VPN connnection Pin
Dave Kreskowiak13-Dec-07 7:20
mveDave Kreskowiak13-Dec-07 7:20 
Generalsub report could not be shown Pin
di3.ny2812-Dec-07 21:38
di3.ny2812-Dec-07 21:38 
GeneralRe: sub report could not be shown Pin
Dave Kreskowiak13-Dec-07 7:22
mveDave Kreskowiak13-Dec-07 7:22 
Questionhow to hide the Start Button in Vista using VB.NET2005 Pin
funakawa12-Dec-07 18:29
funakawa12-Dec-07 18:29 
GeneralRe: how to hide the Start Button in Vista using VB.NET2005 Pin
Michael Sync12-Dec-07 22:24
Michael Sync12-Dec-07 22:24 
GeneralRe: how to hide the Start Button in Vista using VB.NET2005 Pin
funakawa16-Dec-07 16:11
funakawa16-Dec-07 16:11 
QuestionHelp on dymanic installation Pin
highjo12-Dec-07 12:28
highjo12-Dec-07 12:28 
GeneralRe: Help on dymanic installation Pin
Michael Sync12-Dec-07 22:18
Michael Sync12-Dec-07 22:18 
GeneralRe: Help on dymanic installation Pin
highjo13-Dec-07 8:49
highjo13-Dec-07 8:49 
GeneralTO START Pin
Kahuna12-Dec-07 12:14
Kahuna12-Dec-07 12:14 
GeneralRe: TO START PinPopular
Christian Graus12-Dec-07 12:31
protectorChristian Graus12-Dec-07 12:31 
Questionacessing MDI form status bar from other forms/public methods Pin
Adnan Siddiqi12-Dec-07 9:13
Adnan Siddiqi12-Dec-07 9:13 
GeneralRe: acessing MDI form status bar from other forms/public methods Pin
Dave Kreskowiak12-Dec-07 10:19
mveDave Kreskowiak12-Dec-07 10:19 
Generalmoving a Form With No Border Pin
Orlando_Herrera12-Dec-07 8:01
Orlando_Herrera12-Dec-07 8:01 
GeneralRe: moving a Form With No Border Pin
Christian Graus12-Dec-07 8:56
protectorChristian Graus12-Dec-07 8:56 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.