HELO
in order to insert and Update i am using tableAdapte and Dataset, in first look it seems to be working, i do see the insert data in one of my bound controls (listbox) however when i close the app and run it again I DO NOT SEE ANY NEW DATA IN THE TABLE.
i read http://msdn2.microsoft.com/en-us/lib...89(VS.80).aspx
and set the db and dataset Copy to Output Directory to Copy if newer but it still not working.
this is my code:
INSERT AND UPDATE Code:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Me.Validate() Me.CategoryCompanyBindingSource.EndEdit() Me.CategoryCompanyTableAdapter.Insert(CategoryCompanyNameTextEdit.Text) Me.CategoryCompanyTableAdapter.Fill(Me.DatabasecrmDataSet.CategoryCompany) End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Me.Validate() Me.CategoryCompanyBindingSource.EndEdit() Me.CategoryCompanyTableAdapter.Update(CategoryCompanyNameTextEdit.Text, ListBox1.SelectedValue) Me.CategoryCompanyTableAdapter.Fill(Me.DatabasecrmDataSet.CategoryCompany) End Sub
TNX![]()




Reply With Quote