Posted By

nazslash on 11/30/11


Tagged


Versions (?)

this one


 / Published in: VB.NET
 

this one

  1. Private Sub savebtn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles savebtn.Click
  2. Dim registerCus As DataRow = Database6DataSet1.CUSTOMER.NewRow
  3.  
  4. Try
  5. registerCus("Name") = NameTextBox.Text
  6. registerCus("Address") = AddTextBox.Text
  7. registerCus("Telno") = TelNoTextBox
  8.  
  9. Database6DataSet1.CUSTOMER.Rows.Add(registerCus)
  10. OleDbDataAdapter1.Update(Database6DataSet1)
  11.  
  12. MessageBox.Show("Record succsesfully saved")
  13. Catch ex As Exception
  14. MessageBox.Show("Invalid data")
  15. End Try
  16. End Sub

Report this snippet  

You need to login to post a comment.