有2个非常简单的脚本;
function deleteFormulas() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var sh0 = ss.getSheetByName("Social");
var sh1 = ss.getSheetByName("Marchex - Calls");
sh0.getRange("T3:AE").clearContent();
sh1.getRange("F3:L").clearContent();
}
function copyFormulas() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var sh0 = ss.getSheetByName("Social");
var sh1 = ss.getSheetByName("Marchex - Calls");
sh0.getRange("T2:AE2").autoFillToNeighbor(SpreadsheetApp.AutoFillSeries.DEFAULT_SERIES);
sh1.getRange("F2:L2").autoFillToNeighbor(SpreadsheetApp.AutoFillSeries.DEFAULT_SERIES);
}
他们超时了。只有500行。公式是Sumifs,countifs和简单的数学运算。任何使脚本更清晰的方法,或者取决于谷歌表中的公式。