Norberto Soriano
11/22/2017, 10:19 PMandrewh
11/22/2017, 10:23 PMNorberto Soriano
11/22/2017, 10:25 PMigorp
11/22/2017, 10:30 PMNorberto Soriano
11/22/2017, 10:39 PMandrewh
11/22/2017, 10:55 PMandrewh
11/22/2017, 10:56 PMandrewh
11/22/2017, 10:56 PMandrewh
11/22/2017, 10:57 PMandrewh
11/22/2017, 10:58 PMNorberto Soriano
11/22/2017, 11:01 PMNorberto Soriano
11/22/2017, 11:01 PMarindam
11/23/2017, 3:30 PMNorberto Soriano
11/23/2017, 3:41 PMI didn't realize you are in sandbox - the current user when running a scheduled script is System (you can't get the email)Shouldn't PROD work in the same way when sending emails from Scheduled scripts? Which makes me think that emails won't be sent either, and that may be why it doesn't work in PROD for you @arindam; BTW, ¿can you share these settings?
arindam
11/23/2017, 6:02 PMandrewh
11/28/2017, 9:39 PMandrewh
11/28/2017, 9:39 PMandrewh
11/28/2017, 9:40 PMNorberto Soriano
11/28/2017, 9:49 PMvar sender = nlapiGetContext().getSetting('SCRIPT', 'send'); // sender
var recipients = nlapiGetContext().getSetting('SCRIPT', 'recp'); // recipients
var subject = nlapiGetContext().getSetting('SCRIPT', 'subj'); // subject
var body = nlapiGetContext().getSetting('SCRIPT', 'body'); // body
recipients = recipients == null ? new Array() : recipients.split(',');
nlapiLogExecution('DEBUG', 'sender', sender);
nlapiLogExecution('DEBUG', 'recipients', recipients);
nlapiLogExecution('DEBUG', 'subject', subject);
nlapiLogExecution('DEBUG', 'body', body);
nlapiSendEmail(sender, recipients, subject, body);ahomsher
11/28/2017, 9:50 PMNorberto Soriano
11/28/2017, 9:53 PMNorberto Soriano
11/28/2017, 9:54 PMandrewh
11/30/2017, 1:31 AM