How to auto separate MS Lists uploads into separate Sharepoint folders using Power Automate?

Anonymous
2024-04-09T20:38:05+00:00

Hello,

Just realized that MS Lists only allows 1 column for attachments (though allowing multiple attachments). The problem is, I was trying to create multiple columns so the attachments can be added by category.

Since I can't categorize multiple columns, I need to be able to separate the attachments into categorized folders once they are uploaded but I want to do this automatically.

How do I use Power Automate to grab the attachments and place each file in separate SharePoint folders? Thanks!

Lissa

Microsoft 365 and Office | Install, redeem, activate | For business | Other

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

54 answers

Sort by: Most helpful
  1. Anonymous
    2024-06-13T18:32:28+00:00

    Thank you for that information but I do not understand. As mentioned, I am using 2 separate flows because I could not get the single flow to work. I provided the main actions/steps of the 2 flows recently created, none of the 2 flows include parse json as an individual action.

    Please explain in detail what area of the 2 flows you are instructing the formula be added.

    Thanks

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2024-06-12T06:46:08+00:00

    Dear Lissa,

    Thanks for your updates.

    Adding attachments to the site list isn't related to the naming file part in the flow. So you can just add the formula in Compose after you extract the names of the form attachments in the folder in OneDrive for Business or SharePoint Online after the Parse JSON action.

    Welcome to share any updates at your convenience.

    Thank you for your time and effort.

    Sincerely

    Cliff | Microsoft Community Moderator

    Was this answer helpful?

    0 comments No comments
  3. Anonymous
    2024-06-12T02:40:56+00:00

    Hi,

    The MS Form attachments are being added to a SharePoint List so the MS Form data can be reviewed and managed collaboratively. Yes, I'm using the Add Attachment action within an Apply to Each action to place the attachments to the SharePoint List.

    So you're saying removing the name and number may not even be possible and the formula you advised on may be the only possibility. Alright, you've given me the formula. Where exactly am I supposed to place the formula? What action should it be applied to (assuming Apply to Each) and where in the flow I've recently noted should the action and formula be added? Please explain.

    Thanks

    Was this answer helpful?

    0 comments No comments
  4. Anonymous
    2024-06-11T06:01:07+00:00

    Dear Lissa,

    Thanks for your updates.

    I don't know why the form attachments will be added to a site list in your environment. Generally, the form attachments will be automatically saved in OneDrive for Business or a site library in SharePoint Online. Do you use the Add attachment action to add the attachments to a site list?

    However, about the name change, it is by default and you can't change it. The only feasible way is to use the formula I mentioned above to extract the name part like the following and let the flow create new files in another folder.

    substring(items('Apply_to_each_6')?['name'],0,indexOf(items('Apply_to_each_6')?['name'],'_'))

    substring(items('Apply_to_each_6')?['name'] , indexOf(items('Apply_to_each_6')?['name'],'.'), sub(length(items('Apply_to_each_6')?['name']),indexOf(items('Apply_to_each_6')?['name'],'.')))

    Welcome to share any updates at your convenience.

    Thank you for your time and effort.

    Sincerely

    Cliff | Microsoft Community Moderator

    Was this answer helpful?

    0 comments No comments
  5. Anonymous
    2024-06-10T23:44:07+00:00

    Thank you for this information. It has certainly resolved my issue with the toggle button.

    Regarding the flow, I am running out of time for this project and am not having success with getting this to work in a single flow. As I'm pressed for time, I've created two flows (with the help of a few video tutorials). The first flow takes the data and attachments from the MS Form and adds them to the SharePoint List. The second flow takes the attachments that were added to the SharePoint List and adds those attachments to a Document Library.

    I understand this isn't ideal but I need to complete this task immediately. The one problem I'm having is the file name. I need my name and the number to be removed and the attachment to maintain the file name as it is when uploaded. I believe this name change is happening in the first flow. What can I do in flow to prevent the name change so the file name remains the same when added to the SharePoint List?

    Here are the two flows:

    Thanks

    Was this answer helpful?

    0 comments No comments