Hey guys. i am trying to insert data from a form to a sql database, but this error keeps coming up.
Incorrect syntax near ','
Here is the code.
Dim AddSwimmer_comm As New SqlCommand( _
"INSERT INTO [MasterRecords] ([APASCID], [FullName], [Gender], [DOB], [21m], [25m], [50m], [100m], [4x21m], [4x50m]) VALUES ( " & apascidbox.Text & ", " & txt_fullname.Text & ", " & txt_birthdate.Text & ", " & gender.Text & ", " & _21.Checked & ", " & _25.Checked & ", " & _50.Checked & ", " & _100.Checked & ", " & medley_4X21.Checked & ", " & medley_4X50.Checked & "))", AddSwimmer_conn)
AddSwimmer_conn.Open()
AddSwimmer_comm.ExecuteNonQuery()
AddSwimmer_conn.Close()
cheers, michael