C# problem with ADO -
When I use the following code, I get this error:
"Enter the statement in the OleDbexception syntax error
plz help me!
{// new user name system.Data.OleDb.OleDbCommandBuilder cb; cb = new system. Data.OleDb.OleDbCommandBuilder ( Da); DataRow DRow = cPD_DatabaseDataSet.Tables ["users_table"]. NewRow (); dRow [0] = this.textBox_add_user.Text; dRow [1] = this.textBox_password.Text; cPD_DatabaseDataSet.Tables ["users_table"] Rows Add (DRow); // add new record cb.GetUpdateCommand (); cb.GetInsertCommand (); // access file da.Update (cPD_DatabaseDataSet, "users_table"); // Save new recode; Clear textboxes.Textbox_add_user.Text = ""; This.textBox_password.Text = ""; This.textBox_re_password.Text = "";}; hold (System.Data.OleDb.OleDbException exp) {// Connection Close this.con.Close (); MessageBox.Show (exp.ToString ());} `
If you can get a string that represents the inserted statement, then it may be sued, it is quite easy to tell you what the problem is.
Comments
Post a Comment