public void resettime() { Thread.Sleep(5000); resetconfirm = false; ResetButton.Invoke((MethodInvoker) delegate { ResetButton.Text = "Reset"; }); }