Hello Everyone,
Getting below error while adding attachment on mail through instream.
"Adobe Acrobat Reader could not open 'Proof1.pdf' because it is either not a supported file type or because the file has been damaged (for example, it was sent as an email attachment and wasn't correctly decoded)."
Below is the code:
Extension A:
Local_Rec.CalcFields(Local_Rec."PDF Stream");
Local_Rec."PDF Stream".CreateOutStream(NVOutStream, TextEncoding::UTF8);
Local_Rec.Modify();
Extension B:(dependency added of Extension A)
Local_Rec.CalcFields(Local_Rec."PDF Stream");
Local_Rec."PDF Stream".CreateInStream(NVInstream, TextEncoding::UTF8);
SMTPMail.AddAttachmentStream(NVInstream, 'Art.pdf');
Thanks in Advance.