|
-
May 7th, 2013, 08:25 AM
#1
Thread Starter
Hyperactive Member
[Solved] One table not updated using VB 2010 Express and SQL Server 2008 Express DB
I have a Managers table and a Dealership table in my SQL Server 2008 Express Database. (I'm new to SQL Server)
I am using the code below to update the dataset. Changes to the Dealership table are not being reflected in the dataset. They show immediately after the update, but if I close the project and reopen the project, the changes are missing. Changes to the Manager file are reflected just fine.
I just noticed that my TableAdapterManager says "ManagersTableTableAdapter" in properties and there is no TableAdapterManager for the DealershipTable.
Is this OK or not?
What could cause this??
undefined Code:
Me.Validate()
Me.DealershipTableBindingSource.EndEdit()
Me.ManagersTableBindingSource.EndEdit()
Me.TableAdapterManager.UpdateAll(Me.DeiServerDBsDataSet)
Last edited by DexterRose; May 7th, 2013 at 10:39 AM.
-
May 7th, 2013, 10:38 AM
#2
Thread Starter
Hyperactive Member
Re: One table not being updated using VB 2010 Express and SQL Server 2008 Express DB
Well, I may have solved my own problem.
I did not have a key field in the Dealership Table.
I set up a trial project with 3 tables and noticed that the table adapter had an entry for each of the tables in Table Adapter properties.
My problem project must not have added the Dealership Table to the Table Adapter Manager because of the "No Key" field in the Dealership Table.
Hope this Helps someone!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|