Private Sub btnCheckIn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCheckIn.Click
DatabaseConnection.ConnString()
Try
Dim litems As ListViewItem = New ListViewItem()
DatabaseConnection.ConnString()
DatabaseConnection.DataOpen()
DatabaseConnection.Add("INSERT INTO CheckIn(CheckInDate, Deposit, Staying, CheckOutDate, Amount, Balance, Roomnum) VALUES('" & txtCheckIn.Text & "','" & txtDeposit.Text & "', '" & txtStaying.Text & "', '" & DTCheckOut.Text & "', '" & cboRNum.Text & "', '" & txtTotal.Text & "', '" & txtRemain.Text & "')", conn)
DatabaseConnection.Add("INSERT INTO Customer(Guestname, Platenumber) VALUES('" & txtname.Text & "','" & txtPlatenum.Text & "')", conn)
'litems = New ListViewItem()
' LstPrice.Items.AddRange(New ListViewItem() {litems})
MessageBox.Show("process Completed. adding of room done.")
DatabaseConnection.DataClose()
Catch ex As Exception
MessageBox.Show(ex.Message)
End Try
End Sub
i need help when i click check in i want to save the information type in the text box from the form to my datebase in different tables but it has an error when i click check in it says: "data type mismatch in criteria description codes in vb 2008".