Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Unanswered

eMail Templates Attachments - Using SendEmailFromTemplateRequest Class

(0) ShareShare
ReportReport
Posted on by 55

Hi All,

I was added PDF attachment file to existing email template and call the template from the code using SendEmailFromTemplateRequest class as the following code

                   SendEmailFromTemplateRequest sendEmailreq = new SendEmailFromTemplateRequest

                   {

                       Target = email,

                       TemplateId = emailTemplate.Id,

                       RegardingId = regardingId,

                       RegardingType = entRegardingType,

                   };

                   service.Execute(sendEmailreq);

but the attachement file not sent and checking the activity email from CRM side shows that the email was sent without attached file and the attached part is empty

So should i do something else or is there any missing steps.

Thanks,

  • moelshimy Profile Picture
    55 on at
    RE: eMail Templates Attachments - Using SendEmailFromTemplateRequest Class

    Hi there,

    Yes i tried it directly from CRM and working fine but not working in the code.

  • Community Member Profile Picture
    on at
    RE: eMail Templates Attachments - Using SendEmailFromTemplateRequest Class

    Hi partner,

    Have you tried to use the template with PDF attachment to send email directly from crm.

    The result is same with using SendEmailFromTemplateRequest in code?

    Regards,

    Leah Ju

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 293,238 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,923 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156 Moderator

Leaderboard

Product updates

Dynamics 365 release plans