Hello, I have a question for my application, how can I make a button that works automatically, that is, when I click on the button, I choose a number from 1 to 10 and when I choose a number, it automatically returns and chooses a number from 1 to 10 and it only stops when you click on the button again.
Use a button and the clock component for that
Adding to what @Mika said, you have to initially disable the clock, and when the button is clicked, enable it.
When the clock’s timer is fired, set the button’s text to the random value.
If the button is clicked again, disable the clock. (You can have a variable to see if it’s the second time the button is being clicked)