I hav created a database using a windows application form in vc++
i can add and delete entries in the database..
but my prob is that the database s nt getting updated....
it says that "no value given for one or more required parameters"
my update code s as follows
private void BtnUpdate_Click(object sender, EventArgs e)
{
MAcmd.CommandText = "UPDATE table1 "+
"SET info ='"+TxtBoxUpdate_NewVal.Text+"' "+
"WHERE id = "+TxtBoxUpdate_WhereVal.Text;
try
{
int row_affected = MAcmd.ExecuteNonQuery();
MessageBox.Show(row_affected.ToString() + " row affected.", "Update command result");
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
}
i hav given values for both SET INFO (ie TxtBoxUpdate_WhereVal.Text) and WHERE ID (ie TxtBoxUpdate_NewVal.Text)
But i am helpless.... My database s nt updated...
somebody help me... plz.....