Sending Multiple Email Attachments using PT_MCF_MAIL
Hello,
Can someone point out what's wrong with the below code, I am trying to send 2 attachments and it keeps sending only the second attachment twice in the email and doesn't attaches the first one.
Local PT_MCF_MAIL:MCFBodyPart &Hf_text = create PT_MCF_MAIL:MCFBodyPart();
Local number &hfarray_id = 0;
&Hf_text.Text = &MAIL_TEXT;
&Hf_email.ContentType = "text/html";
Local PT_MCF_MAIL:MCFBodyPart &Hf_attach = create PT_MCF_MAIL:MCFBodyPart();
Local PT_MCF_MAIL:MCFMultipart &Hf_mp = create PT_MCF_MAIL:MCFMultipart();
&Hf_mp.AddBodyPart(&Hf_text);
&hfarray = Split(&MAIL_FILES, ";");
&hf_filename = Split(&MAIL_TITLES, ";");
While &hfarray.Next(&hfarray_id)