I'm Having a problem in it, don't what what it is : m having a syntax error
OleDbCommand com = new OleDbCommand("update cus SET cus_name = ('" + textBox4.Text + "'),order=('"+textBox6.Text+"') WHERE no = ("+textBox5.Text+")", con);
Jump to Post
And try to use Parameters, so you dont assign values directly into the query, but in query you only write parameters, which you then add bellow.
OleDbCommand com = new OleDbCommand(@"UPDATE cus SET cus_name = @param1, order = @param2 WHERE no = @param3", con); com.Parameters.Add("@param1", OleDbType.VarChar, …
All 2 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.