Discussions
Read on for the latest updates including:
• Agenda Builder launch
• SuiteWorld On Air registration
• New NetSuite Prompt Studio Contest
• And more!
Check out this thread to learn more!
\n new line character is not being picked up in Suitescript
Why does'nt the following code insert a new line character (\n) in the body of email message
PDFfile = nlapiPrintRecord('TRANSACTION', invoiceRec.getId(), 'PDF', null);
MsgHeader = 'Hi ' + contactRec.getFieldValue('firstname') + '\n\n';
MsgFooter = 'Regards\n\n' + salesrepRec.getFieldValue('addrtext') + '\n\n' + salesrepRec.getFieldValue('phone');
Msg = MsgHeader + msg30daysoverdue + MsgFooter;
nlapiSendEmail(invoiceRec.getFieldValue('salesrep'), 'x@a.com;', 'Your Invoice is OverDue', Msg, null,null,null,PDFfile);
The \n in the string variables above is not replaced with new line in the output. I do'nt know, Why?