Hello all, I have a general question. I am trying to figure out how to do a update from a visual basic 2005 to a SQL server 2005 database. Currently, I have the application connecting and retrieving data from the database. But I can't seem to figure out how to do an update. I will explain what I am trying to do. As an example, a user searches for a certain customer and then upon finding some info for that customer, user wants to update / enter some new info about customer by providing input into certain form controls (textboxes, comboboxes etc). After user has finished entering the info and then clicks the 'Save' button, those values should be passed back into the database and from there to the actual database.
I think this can be done through two similar ways. One way is to create an Update query under the appropriate table adapter in designer mode of the dataset and then in the vb form code, pass the appropriate values to the query. However, I am not sure what this query in the tableadapter should look like and how to pass the values to it. The other way to do this task I think is by declaring and setting the appropriate sql connection string, the dataadapter, sql query as the sql command text, the dataset in the form's vb code. One important thing to note is that I don't want to do this task through a toolstrip and the automatically created save button on there. I am using a regular vb button to initiate the event to update. Thanks in advance.
