hi all,
i'm having a problem binding my combo box to my data table
i have these codes that binds my combo box.
this code works well only when reading data... it automatically selects the correct item in my combo box to whatever was saved to that column in my table... however, when editing or updating the combo box text, it doesn't update.Code:combo.DataBindings.Add("Text", DataTable, "status")
so then i tried these codes
unfortunately this won't work with the reading and updating.Code:combo.DataSource = Datatable combo.DisplayMember = "status" combo.Items.Add("MARRIED") combo.Items.Add("SINGLE") combo.Items.Add("WIDOWED")
considering that i have all my adapter insert, update, delete command set already and are actually working with databinds in a textbox control.
any thoughts? thanks...




Reply With Quote