Hey Grig,
You're mixing apples and oranges here. If you're going to use the Update() method, you don't specify the parameters. The Update() method will go through your Table and insert the records that are marked as Added. It will set up the parameters for you. My guess is that you don't have any rows to add ... either you've already done an AcceptChanges() on your DataTable, or you didn't insert a row into it.
~~Bonnie
>This is driving me crazy again.
>
>I have an OleDbDataAdapter. I've set it's Insert command and it looks like this:
>
>
>OleDbDataAdapter.InsertCommand.CommandText = "Insert into table (field1, field2) Values (@par1, @par2)"
>OleDbDataAdapter.InsertCommand.Parameters.Add("@par1","value1")
>OleDbDataAdapter.InsertCommand.Parameters.Add("@par2","value2")
>OleDbDataAdapter.Update(dsTable)
>
>
>It doesn't insert the row and it doesn't raise any error. How to overcome this? what I am doing wrong? I've already wasted half of a day and I can't afford any time waste anymore. If there is a better way to do this, please help me.
>
>Thanks.