I have formatted data being added to a Modal Dialog when I click a button
I want to the content of the showModalDialog()
to be automatically added to the clipboard when I click the button as well
The modal is being generated with the below code, and temp
is the output I want added to the clipboard
//Output to Html
var htmlOutput = HtmlService
.createHtmlOutput(temp)
.setSandboxMode(HtmlService.SandboxMode.IFRAME)
.setWidth(600)
.setHeight(500);
SpreadsheetApp.getUi().showModalDialog(htmlOutput, 'Filter OptionList Maker');
Edit; Ok, I guess maybe the Modal Dialog
might be beside-the-point and the proper question might be how to add the formatted string temp
to the clipboard
Here is an example of what I mean by formatted string
filter {
target: element;
as: dropdown;
padding: 5;
summary: "Network Practice";
default: show-all;
multiple: true;
option {
label: "< 1 year";
selector: element["NETWORK PRACTICE"="< 1 year"];
}
option {
label: "1-3 years";
selector: element["NETWORK PRACTICE"="1-3 years"];
}
option {
label: "3-10 years";
selector: element["NETWORK PRACTICE"="3-10 years"];
}
option {
label: "> 10 years";
selector: element["NETWORK PRACTICE"=">10 years"];
}
}
I have searched on how to do this but I have found no solution
Thanks
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…