mardi 29 septembre 2020

I'm trying to create a loop that will close down a form when a progressbar hits 100

I'm trying to make it so that if a checkbox is checked, and a progressbar hits 100, the application will close. The problem is that i need the progressbar1.value to be in a loop until the value hits one hundred.

after that it should close the application, but only if both the checkbox has been checked and the progressbar at 100

           timer1.Start();
            if (CheckBox1.Checked)
            if (progressBar1.Value == progressBar1.maximum)
                    Application.Exit();```

Aucun commentaire:

Enregistrer un commentaire