When I connect to a database and try to make changes, I cannot get it to save my changes to the dataset. When I Start the program and make a change and hit the SaveItem button, then close the form and restart the program the changes are not saved. Here is the code that is automatically created for the SaveItem button:




Is there something I should add to this

I also tried adding the last 2 lines to the FormClosing Event (how it shows in the VB Express Help) and still nothing. What am I doing wrong



Re: Visual Basic Express Edition Saving Data to a DataSet


Verify that you are not overwriting the database.

Go to the Solution Explorer and right click on the database file and check its properties - is it set to copy always. Then every time you start up your application it will copy the database file to the bin directory which would blow over any changes you had made when previously running the app.

Set it to copy if newer or never copy and place a copy of the database in the bin folder yourself.

Check out thread

http://forums.microsoft.com/msdn/ShowPost.aspx postid=467084&isthread=false&siteid=1

For more details which may help you.