Is there a way to use radio buttons in a Google Sheets Dialog and save the value, using Google App Scripts?

前端 未结 3 1253
没有蜡笔的小新
没有蜡笔的小新 2021-01-26 20:41

My goal, simply put, is to highlight a cell range on one google sheet (the \'source\') and move it to another, different google sheet document (the \'target\'). The Target has

3条回答
  •  长发绾君心
    2021-01-26 21:13

    Here's a simple example of a radio dialog:

    function radiosOnADialog() {
      var ss=SpreadsheetApp.getActive();
      var sh=ss.getActiveSheet();
      var html='';
      for(var i=0;i<10;i++) {
        html+=Utilities.formatString('
    %s','id'+ Number(i+1),'radio' + Number(i+1),' radio' + Number(i+1)); } html+='
    '; html+=''; var ui=HtmlService.createHtmlOutput(html); SpreadsheetApp.getUi().showModelessDialog(ui, 'A Radio Dialog'); }
    • Radio Buttons

    The Dialog:

提交回复
热议问题