I have a Google Sheet that adds multiples rows per day as forms get entered.
What's the best, most hands-off way to apply formulae to rows as they get added?
I've built a script, but it applies the formulae to every row in the column... I'd like to limit it to only rows that have data, for example only if Col A has a timestamp... I can't seem to get IF statements to work properly here...
Here's my script so far...
function AutofillC() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var sheet = ss.getSheets()[0];
var cell = sheet.getRange("C2:C");
cell.setFormula("=CONCATENATE(AG2:AX2)");
var cell = sheet.getRange("D2:D");
cell.setFormula("=WEEKDAY(I2)");
var cell = sheet.getRange("E2:E");
cell.setFormula("=month(I2)");
var cell = sheet.getRange("F2:F");
cell.setFormula("=sum(I2:AF2)");
var cell = sheet.getRange("G2:G");
cell.setFormula("=$G$1&ROUNDDOWN((H2-'REFERENCE INFO'!$A$2)/14)");
}