Hello Friends I am using Microsoft Visual Studio 2005 and ms-acess 2000 to build very simple database application
Here is my Code of Conncetion:
con = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|\db1.mdb")
sql = "INSERT INTO emp values(@op1,@op2)"
cmd = New OleDbCommand(sql, con)
cmd.Parameters.AddWithValue("@op1", TextBox1.Text)
cmd.Parameters.AddWithValue("@op2", TextBox2.Text)
con.Open()
cmd.ExecuteNonQuery()
con.Close()
This is simple code to insert data from textbox to table row
But Whenever i run it did not give me error but when i check on database the record is not there.
What should i do?????
Please Guys Help Me Out.
thanks in advance..