Generate objects by clicking the button.