سؤال

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++;
        }
    }

لا يوجد حل صحيح

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top