This is driving me crazy, someone please help.. i'm trying to insert new records into a table in an access database and what i have done so far is set up a connection using the data link property (oleDB connection), i've set up a oleDB command and on my button (which when users click, it'll insert the record", i have the following code:
With cmdRegister
.Parameters("@email").Value = txtbox1.Text
.Parameters("@password").Value = txtbox2.Text
End With
OleDbConnection1.Open()
cmdRegister.ExecuteNonQuery()
OleDbConnection1.Close()
lblmessage.Text = "Congratulations, you are
now registered"
Now under the properties of my cmdRegister command, i've set up the parameters @email and @password. The part that is driving me crazy is the commandtext, i typed in the following code: INSERT INTO dbo.logininfo (E - Mail, password) VALUES (@ email, @ Password) but it keeps giving me "error in column list '-' not recognized, error in column list'@' not recognized, unable to parse query text.. can someone please tell me what i am doing wrong here, am i typing the command text wrong.. ???? Helpp
With cmdRegister
.Parameters("@email").Value = txtbox1.Text
.Parameters("@password").Value = txtbox2.Text
End With
OleDbConnection1.Open()
cmdRegister.ExecuteNonQuery()
OleDbConnection1.Close()
lblmessage.Text = "Congratulations, you are
now registered"
Now under the properties of my cmdRegister command, i've set up the parameters @email and @password. The part that is driving me crazy is the commandtext, i typed in the following code: INSERT INTO dbo.logininfo (E - Mail, password) VALUES (@ email, @ Password) but it keeps giving me "error in column list '-' not recognized, error in column list'@' not recognized, unable to parse query text.. can someone please tell me what i am doing wrong here, am i typing the command text wrong.. ???? Helpp