I'm using the below script to capture the entry_timestamp of every new row that gets imported from a different Google Spreadsheet using the 'IMPORTRANGE' function.
function onEdit(e) {
var ss = e.source.getActiveSheet();
if (ss.getName() !== 'Raw Data' || e.range.columnStart !== 3) return;
e.range.offset(0, -2)
.setValue(e.value ? new Date() : null);
}
While the above snippet works like charm every time I "edit" something in col.C, I would like the same functionality whenever a new line item gets inserted because of changes in the other spreadsheet which I'm reading using the IMPORTRANGE function.
Can any expert help me with that? I have created a sample sheet for your reference here
Any help is much appreciated :)