Skip to content

Instantly share code, notes, and snippets.

@slayton
Last active April 4, 2020 00:39
Show Gist options
  • Save slayton/1c04efc76c8c4e5a753f48b008eb5da7 to your computer and use it in GitHub Desktop.
Save slayton/1c04efc76c8c4e5a753f48b008eb5da7 to your computer and use it in GitHub Desktop.
function onEdit(e) {
var row = e.range.getRow();
var col = e.range.getColumn();
if (col>=2 && col<=13 && row < 3 && e.source.getActiveSheet().getName() === "Temperature") {
e.source.getActiveSheet().getRange(row,14).setValue(new Date());
if (e.source.getActiveSheet().getRange(row,1).getValue() == "") {
e.source.getActiveSheet().getRange(row,1).setValue(new Date());
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment