Increase value of numericUpDown by 1 and press a button at the same time
-
19-10-2022 - |
Question
I'm trying to make a function which can be used to increase the value of a numericUpDown and press a button at the same time but this is giving me problems any idea how to make it better ? Making a project and need this function so i don't need to create a new case that is if a person wants to choose all then it goes from value 1 to 10 and each time the button is clicked along with it.
private void PlusClick(NumericUpDown numericUpDown, Button button, int start, int stop)
{
for (start = (int)numericUpDown.Value; start < stop;)
{
numericUpDown.UpButton();
button.PerformClick();
start++;
}
}
No correct solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow