cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper I
Helper I

Power Automate Flow to upload documents within document set

Hi All,

 

I've written a flow which will take the inputs from PowerApps form created for a list and will create a folder structure in a library. Within that folder structure it will also create a document set. Now, I've one more requirement. I need to add attachments in the same PowerApps form created for a list and this time the flow should also add those attachments as documents within the newly created document set in document library.

I've gone through the blogs to add document to document library from PowerApps form but I need to add that too after creation of document set. Can anyone suggest me on this?

 

Thanks,

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Advocate V
Advocate V

Re: Power Automate Flow to upload documents within document set

Very good!

So the steps are:

  1. User opens Power App and can add attachments
  2. When submitting a form, an item in SharePoint is saved with attachments
  3. You trigger a flow to create a document set
  4. After the document set is created, every attachment should be transfered (copied) to the document set

Step 4 is causing you issues when I look at the screenshot linked to your blog post.

So the first thing you should limit for good troubleshooting is to start with a file like PDF or Word because in my experience not all actions in a flow will work with all type of files. So first let us get your flow working with a PDF file attachment as these are the safest kind 😁.

 

First thing to tourbleshoot is to see if your Step 3 can be causing an issue. Could you create a second simple Flow that does basically the same steps regarding document creation but without the document set part --> just get attachments + apply to each attachment + get attachment content + create file but select a library that you know is existing instead of a variable??

View solution in original post

5 REPLIES 5
Highlighted
Advocate V
Advocate V

Re: Power Automate Flow to upload documents within document set

Hi @basukunal001 ,

Do you have a Flow directly linked to the Power App or do you store your Power App Data somewhere in a record (like a SharePoint List) and then a separate Flow is triggered on that record?

 

Highlighted
Helper I
Helper I

Re: Power Automate Flow to upload documents within document set

Hi Django,

 

I got a way to implement this. I can copy the attachments from PowerApp form in list to document library. I've followed the below blog to implement it.

https://powerusers.microsoft.com/t5/Power-Automate-Community-Blog/Moving-PowerApps-Attachments-to-a-...

 

But I've got some issues. If I try to upload text file as attachment, the flow runs fine but nothing got uploaded to library. When I try to upload .docx file or .xlsx file, the flow throws an error.

 

I've shown the steps on that above blog at the bottom.

 

Thanks,

Kunal

Highlighted
Advocate V
Advocate V

Re: Power Automate Flow to upload documents within document set

Very good!

So the steps are:

  1. User opens Power App and can add attachments
  2. When submitting a form, an item in SharePoint is saved with attachments
  3. You trigger a flow to create a document set
  4. After the document set is created, every attachment should be transfered (copied) to the document set

Step 4 is causing you issues when I look at the screenshot linked to your blog post.

So the first thing you should limit for good troubleshooting is to start with a file like PDF or Word because in my experience not all actions in a flow will work with all type of files. So first let us get your flow working with a PDF file attachment as these are the safest kind 😁.

 

First thing to tourbleshoot is to see if your Step 3 can be causing an issue. Could you create a second simple Flow that does basically the same steps regarding document creation but without the document set part --> just get attachments + apply to each attachment + get attachment content + create file but select a library that you know is existing instead of a variable??

View solution in original post

Highlighted
Helper I
Helper I

Re: Power Automate Flow to upload documents within document set

Hi Django,

 

It seems I've fixed the issue. I went to "Create File" action >> Settings and then disabled 'Allow Chunking'. It worked.

 

Thanks,

Kunal

Highlighted
Advocate V
Advocate V

Re: Power Automate Flow to upload documents within document set

Thank you for sharing @basukunal001 !

 

Chunking would not be something, I would have come up in the first few trouble shooting steps 😁

Helpful resources

Announcements
firstImage

Super User Program Update

Three Super User rank tiers have been launched!

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

Top Solution Authors
Users online (9,295)