1

My only experience with VB and SQL was 10 years ago when I made a webform application. That one worked great. This is the first time I'm creating a local sql server database to be used in VB. I'm using VS 2015. My first issue cam up with my first and only test "customers" table with my first entry.

  1. Created a local DB via sql server management studio 2016 and made one table - 'customers'.
  2. Connected to DB in VS 2015. Connection successful.
  3. Added a form and created a dataset and dragged the 'customers' table to form. All is well.
  4. Tried to add a customer via the VB form but VB was showing -1 as the first index instead of 1001 that I had defined to be the first seed.
  5. Thought I'd deal with this later so I closed VS and opened SQL management and added the customer there. All was fine. Index was 1001.
  6. Closed the SQL manager and reopened it to see if the data was still there... it was - one row. Great.
  7. Opened the VS project... the data was gone. NO rows in the table.
  8. Closed the VS and opened the SQL manager... also there the data was gone... no rows.

It's like VS is deleting the data in the table when I open the VS project!

What can be wrong?

0 Answers0