G
Guest
I've created an extremly simple form for testing. I want to add records
using bound textboxes.
I've created a connection by dragging a SQLdataAdapter on to the form and
using the Wizard with no special conditions. (Just select * from a single
table.) I've bound a few textboxes to the fields (4 boxes and a
DateTimePicker to be exact). I fill the dataset on form load and I know I'm
getting data then.
My problem is this: Nothing I do will create a new row. I'm trying to add a
record with what I thought were the usual means.
Me.BindingContext(Me.DataSet31, "OrderH").EndCurrentEdit()
Me.BindingContext(Me.DataSet31, "OrderH").AddNew()
(The number of rows in the table does not increase and when I go to the
Update call there is no row with DataRowState = Added.)
What am I forgetting?
using bound textboxes.
I've created a connection by dragging a SQLdataAdapter on to the form and
using the Wizard with no special conditions. (Just select * from a single
table.) I've bound a few textboxes to the fields (4 boxes and a
DateTimePicker to be exact). I fill the dataset on form load and I know I'm
getting data then.
My problem is this: Nothing I do will create a new row. I'm trying to add a
record with what I thought were the usual means.
Me.BindingContext(Me.DataSet31, "OrderH").EndCurrentEdit()
Me.BindingContext(Me.DataSet31, "OrderH").AddNew()
(The number of rows in the table does not increase and when I go to the
Update call there is no row with DataRowState = Added.)
What am I forgetting?