I have an access table that I'm loading into a dataset, then I'm binding the dataset to a bindingsource. The bindingsource is the datasource for a datagridview. I can use a command builder to update the entire table, but I need to update all the rows (or changed rows) in specific columns. I have a column called "dPrint" which is Boolean. I'm not sure how to use the bindingsource as my datasource in an Update Command. I've tried this:
Am I on the right track here? Can someone help me out? ThanksCode:' This is at the top of my form, used to add new rows Dim row As DataRowView Dim updateCommand As New OleDbCommand("UPDATE Customers SET dPrint = @dPrint", Conn) updateCommand.Parameters.AddWithValue("@dPrint", row("dPrint")) updateCommand.Connection = Conn Conn.Open() updateCommand.ExecuteNonQuery()




Reply With Quote