button.doClick(); //optionally, give an integer argument for the number of milliseconds to hold the button down