hello,
I am not at all sure if this is possible. I have for previous canvas apps PDF the data from Power Apps, using Power Automate.
I now have a requirement to place all the attachments (SharePoint is the data source) a user uploads in the app and export them into the same PDF as the data (text). I am not sure if this has been attempted, but I will be restricting users to only be able to upload image file types in the attachment control.
In theory I expect this is possible but cannot find the right information online
Thank you
Solved! Go to Solution.
Hi @Anonymous ,
It is possible, but the maximum size of the PDF is 2mb. Below is an example from one of my Flows - this is getting the files from a SharePoint Library based on an identifier.
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Visit my blog Practical Power Apps
Hi @Anonymous ,
It is possible, but the maximum size of the PDF is 2mb. Below is an example from one of my Flows - this is getting the files from a SharePoint Library based on an identifier.
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Visit my blog Practical Power Apps
Hello @WarrenBelz
Would this work if my attachments were stored in a list item?
The 2mb limit of the pdf seems quiet small, I presume there is a reason for this and it cannot be increased?
@Anonymous ,
You could send the ID and use Get Attachments then Apply to each and Get Attachment Content and then the rest as per the Library.
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Visit my blog Practical Power Apps
Hi Warren,
Thank you for your responses, I will come back to you in a few days I've been asked to work on something else. Once I have attempted your suggestions I will let you know if I require any more help or if it is working.
Thank you once again
Hello @WarrenBelz
Sorry about not coming back to this sooner I was moved off this project.
I am finally attempting this and struggling at the start:
My trigger is when an item is created or modified.
Then I get attachments - get attachment contents.
I attempted to get file properties but this is for doc libraries only it appears.
I attempted to Append to string variable action, but again I have no option in the Name field as yours is pointing to a doc lib i presume... are you able to advise what I am doing wrong as per your first response?
Thanks
Hi @Anonymous ,
You need to initialise the Variable first (this was further up my Flow). I wanted to work this one out anyway and the below works fine and emails the PDF file back
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Visit my blog Practical Power Apps
Hi @WarrenBelz
Thanks for the detailed instructions with screen shot, I seem to be stumbling across a problem in the append to sting variable function:
Tried a number of times but the expression won't save
@Anonymous ,
My expression that works is
dataUri(outputs('Get_attachment_content')?['body'])
The other content on both sides is Text
Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.
Visit my blog Practical Power Apps
Thanks @WarrenBelz
That's solved that issue, do you have any issues opening the PDF?
I get this when I attempt to open the file from the email or from OneDrive:
But I can see the merge was successful in the HTML file in the OneDrive folder, so it appears the conversion to PDF is failing, any ideas what I may have done wrong:
User | Count |
---|---|
124 | |
87 | |
86 | |
75 | |
69 |
User | Count |
---|---|
214 | |
181 | |
140 | |
96 | |
83 |