This is the error I'm getting:
with this code:
private void button1_Click_1(object sender, EventArgs e)
{
if (txtID.Text == "" || txtName.Text == "" || txtMobileNo.Text == "")
{
MessageBox.Show("Please Enter all of your detail.", "Stop", MessageBoxButtons.OK, MessageBoxIcon.Stop);
}
else
{
string query = "INSERT INTO tablemm (id,Name,MobileNo) VALUES ('" + txtID.Text + "','" + txtName.Text + "','" + txtMobileNo.Text + "')";
OpenConnection();
MySqlCommand ObjCommand = new MySqlCommand(query, ObjConnection);
ObjCommand.ExecuteNonQuery();
this.CloseConnection();
}
}