Error saving SQL table: TableAdapterManager contains no connection information.

Hi, just getting to grips with SQL and VB 2008. I have a simple form with a single table called customers.

When i click the 'save' button on the CustomerBindingNavigator i get an error "TableAdapterManager contains no connection information. Set each TableAdapterManager TableAdapter property to a valid TableAdapter instance."

If i run the code behind the save button on another button it works fine, doesn't make sense to me...

Please help before i go insaine.
Private Sub CustomerBindingNavigatorSaveItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CustomerBindingNavigatorSaveItem.Click
        Me.Validate()
        Me.CustomerBindingSource.EndEdit()
        Me.TableAdapterManager.UpdateAll(Me.Dataset_customers)  ' I GET THE ERROR HERE
    End Sub
 
    ' THIS CODE WORKS FINE!
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Me.Validate()
        Me.CustomerBindingSource.EndEdit()
        Me.TableAdapterManager.UpdateAll(Me.Dataset_customers) 
    End Sub

Open in new window

bassl1neAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

James MurrellProduct SpecialistCommented:
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
bassl1neAuthor Commented:
Thanks, i have checked out the link but it does not provide additional information required to solve my problem.

I am sure if i recreated the form it would work ok as it did originally, i suspect something deeper in the generated code has gone wrong. The reason i ask the question rather than simply recreate the form it because i would like to learn how to debug these faults rather than starting all over again as seems to be the case at the moment.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Visual Basic Classic

From novice to tech pro — start learning today.