private void materialFlatButton1_Click(object sender, EventArgs e) { if (numeric.Value < 200 || numeric.Value > 10000) { MessageBox.Show("Wrong values"); } else { DBUtils.OpenConection(); DBUtils.ExecuteQueries(string.Format("UPDATE User_level SET user_speed = {0} WHERE Id=1", numeric.Value)); DBUtils.CloseConnection(); cbMain.LoadTex(); mainForm.CheckForAutoCalibration(false); this.Close(); } }
private void Calibration_FormClosing(object sender, FormClosingEventArgs e) { cabMain.LoadTex(); mainForm.UserLevelCheck(); }