web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Office365Outlook.SendE...
Power Apps
Answered

Office365Outlook.SendEmailV2 ContentBytes: PDF resize in format A4

(0) ShareShare
ReportReport
Posted on by 566

 

Hello,

I have this formula below which creates PDF file from my gallery3 and send it by email.

Office365Outlook.SendEmailV2( 
 "test@mail.com";
 "objtext" ;" bodytext ";
 { 
 Attachments: Table( 
 { 
 Name: "test.pdf"; 
 ContentBytes: PDF(Gallery3;{Orientation:"portrait";ExpandContainers: true; Margin:"5mm"; Size:PaperSize.A4}) 
 } 
 ) 
 } 
 ) 

 The issue i have is when the PDF file is created, the images of my gallery are not resized in A4 format. 

Could you help me please?

Categories:
  • WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    Hi @Sormick ,

    The experimental PDF function still has a number of bugs / shortcomings, one of which is the handling of images. There are no settings beyond Paper Size, Margins etc that will help you here, so unfortunately there is not much you can do presently.

  • Sormick Profile Picture
    566 on at

    @WarrenBelz 

    Thank you,

    Please, do you know how to add a second PDF file as attachement?

    Try this but did not worked

    Office365Outlook.SendEmailV2(
     "cei.sav@laposte.fr";
     "Your pdf";
     "Your PDF is attached";
     {
     From: "cei.sav@laposte.fr";
     Attachments: Table(
     {
     ContentBytes: PDF(
     Gallery3;
     {
     Orientation: PaperOrientation.Portrait;//Portrait or Landscape
     Size: PaperSize.A4;//Select your page size
     DPI: 10;
     ExpandContainers: true /* This property makes sure the full content of gallery/containers is expanded as PDF */
     }
     );
     Name: "Export.pdf"
     }&
     {
     ContentBytes: PDF(
     Gallery4;
     {
     Orientation: PaperOrientation.Portrait;//Portrait or Landscape
     Size: PaperSize.A4;//Select your page size
     DPI: 10;
     ExpandContainers: true /* This property makes sure the full content of gallery/containers is expanded as PDF */
     }
     );
     Name: "Export2.pdf"
     }
     )
     }
    )
  • Verified answer
    WarrenBelz Profile Picture
    156,921 Most Valuable Professional on at

    @Sormick ,

    The first thing I can see is that you have & between the two files instead of ;

  • Sormick Profile Picture
    566 on at

    Thank you! i replaced ";" with & and now it works!

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 236 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 207 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 169

Last 30 days Overall leaderboard