Private Sub Btnsave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Btnsave.Click
If Not IsDataCompete() Then
Exit Sub
End If
SQL = "INSERT INTO raiooy(RaiDate,Menu,Type,Count,Price,Total)" & "VALUES(@RaiDate,@Menu,@Type,@Count,@Price,@Total)"
AddParameters(SQL)
Dim r As Integer = Command.ExecuteNonQuery()
If r > 0 Then
MessageBox.Show("บันทึกข้อมูลแล้ว")
Btnadd.PerformClick()
Else
MessageBox.Show("เกิดข้อผิดพลาดในการบันทึกข้อมูล")
End If
End Sub
error Dim r As Integer = Command.ExecuteNonQuery() ค่ะ
ช่วยดูให้หน่อยนะค่ะ