Send email,
I am trying to create a send email script, enter image description here, any cell in H column reach to 1 send me email with a certain message, any support from anyone. I already out the email with the email in the sheet.
I am trying to use this script,
function ifstatement() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var sheet = ss.getSheetByName("Sheet 1");
var value = sheet.getRange("b2").getValue();
if(value >= "1") sendEmail(value)
};
function sendEmail(value){
var recipient="[email protected]";
var subject=" test subject " +value;
var body=" test body "+value;
MailApp.sendEmail(recipient, subject, body);
}
You want to send an email IF the value in Column H is changed to 1.
The script needs an installable
onEdittrigger.