|
I'm working with a vb windows forms app and using LINQ to SQL. I have a form whose values come from a SQL table. one of the items on this form is a combobox whose items come from another SQL table. My form works great when I am loading an existing record from my table and now I am trying to add the ability to create a new record with this same form. I created a new instance of the table and set my form's bindingsource's datasource to it. This all works. Now I need to set the combobox, which is data bound with its own bindingsource, to a default value. I have tried setting the combobox's .SelectedValue to the default value that I want but that doesnt work. I'm sure this is a very simple matter, so simple that the answer is hard to find, at least for me. Thanks for any suggestions. UPDATE: now i noticed that i cannot update the value of a textbox (via texbox1.text="whatever") either. the answer must lie in the databinding. - Edited byjdroger2 Wednesday, August 26, 2009 5:00 PMnew info
-
|