How do I modify a button from a function in Google Apps Script UI App
I have created a UI App Form Panel in Google Apps Script with the following following button definition:
var voteButton = app.createButton('Submit');
var handler = app.createServerClickHandler('buttonPressed');
handler.addCallbackElement(formContent);
voteButton.addClickHandler(handler);
the severClickHandler is set to call the following functio开发者_运维问答n:
buttonPressed(){
//do something .....
}
This works well, but I need to disable the voteButton once the execution og the buttonPressed() function is completed successfully. How can set voteButton to not visible. Is there a way I can pass the vote button to the buttonPressed function?
Jesse, over at the Google App Script forum, has answered this question: Server Click Handler
精彩评论