Hi friends,
I want to send a email automatically in NAV 2016,
This is my code
PdfDocPath :='ABC.pdf';
Path := 'C:\\Temp'+PdfDocPath; // Directory + Path
CLEAR(ABC); // ABC is a Report 50088
ABC.USEREQUESTPAGE(FALSE); //// for filteration
IF NOT ABC.SAVEASPDF(Path) THEN
ERROR('PDF Creating Failed!\\ERROR:\\' + GETLASTERRORTEXT);
SMTP.CreateMessage('Jonas Wood','ashwini.e@sharpsyssoft.com','','Outstanding Amount','',TRUE) ;
SMTP.AddCC('ashwini.e@sharpsyssoft.com');
SMTP.AppendBody('Dear Sir / Madam,');
SMTP.AppendBody('<br><br>');
SMTP.AppendBody('Please find the Customer Outstading Amount in PDF Format:');
SMTP.AppendBody('<br><br>');
SMTP.AppendBody('Regards');
SMTP.AppendBody('<br>');
SMTP.AppendBody('Company Accounts Departments ');
SMTP.AddAttachment(Path,PdfDocPath);
SMTP.Send;
//ERASE(Path);
i can send a mail but not automatic but i want send a mail automatically in NAV 2016 please give any suggestion.
Thank you
*This post is locked for comments