Updating a DataSet with a ComboBox

C

Christopher Weaver

I would like my user to be able to type in a value or select one from the
dropdown of a ComboBox. I've set the DropDownStyle to DropDown so that they
can do both within the component. But I can't seem to get the value typed
in to replace the original value in the DataSet as it would in a text box.

Anyone know how to do this?
 
G

Guest

I would like my user to be able to type in a value or select one from the
dropdown of a ComboBox.

As far as I know, you have to write the code to do this. You could use a
suitable event to do it immediately, or wait until the save to the database.
Same with ListBox.

e.g.

dsCompany.Tables[0].Rows[0]["prefix"] = cbPrefix.Text ;
 

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