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 / Image to PDF with dyna...
Power Apps
Unanswered

Image to PDF with dynamic file name

(0) ShareShare
ReportReport
Posted on by 353

Hi Community,

 

I have an application made up of a "text input", an "add image" input, and a button to run a flow in Power Automate that takes the image and converts it to a PDF file. The file name is the text that is added in the "text input".
In the button to run the flow, what would be the problem?

 

OneSelect in Botton: ETF2.Run(TextInput1.Text;{file: UploadedImage1_4.Image;IncludeBinaryData})

 

ETF2 is the name of the P.Automate stream.
TextInput1 is the name of the text input to add the file name.
UploadedImage1_4 is the input to add the image.

 

Thanks,

Categories:
I have the same question (0)
  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi @Francisco77 ,

     

    Please try:

    ETF2.Run( 
     TextInput1.Text; 
     { 
     file: { 
     name: TextInput1.Text; 
     contentBytes: Substitute(JSON(Substitute(JSON(Image1.Image;JSONFormat.IncludeBinaryData);"""";"");JSONFormat.IncludeBinaryData);"""";"");
     } 
     } 
    )

     

    Best Regards,

    Bof

  • Francisco77 Profile Picture
    353 on at

    Hi @v-bofeng-msft,

     

    The formula does not show errors, but the image that is loaded in the file that is generated is wrong.

     

    Francisco77_1-1695609417046.png

     

    Thanks for youre help¡

  • Francisco77 Profile Picture
    353 on at

    Of course¡

     

    Francisco77_0-1695609728331.png

    Francisco77_1-1695609868222.png

    Francisco77_2-1695609960608.png

     

    Thanks,

     

  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi @Francisco77 ,

     

    Please try:

     

    ETF2.Run( 
     TextInput1.Text; 
     { 
     file: { 
     name: TextInput1.Text; 
     contentBytes: Image1.Image;JSONFormat.IncludeBinaryData
     } 
     } 
    )

     

    vbofengmsft_0-1695610392787.png

    vbofengmsft_2-1695610426911.png

     

    vbofengmsft_1-1695610410348.png

     

    Best Regards,

    Bof

  • Francisco77 Profile Picture
    353 on at

    Thanks but I see this error.

     

    Francisco77_0-1695611193083.png

     

  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi  @Francisco77 , 

    Please delete 

    ;JSONFormat.IncludeBinaryData

     vbofengmsft_0-1695611794927.png

    Best Regards,

    Bof

  • Francisco77 Profile Picture
    353 on at

    thanks @v-bofeng-msft ,

     

    But the image in the file created is incorrect¡.

     

    Francisco77_0-1695612252150.png

     

  • Francisco77 Profile Picture
    353 on at

    Hi @v-bofeng-msft 

     

    I tried the formula but it gives me an error that says: The "contentbytes" column is missing from the formula with a type of "Blob".

     

    Regards,

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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 358 Most Valuable Professional

#2
11manish Profile Picture

11manish 214 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 179

Last 30 days Overall leaderboard