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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Can the List Folder Ac...
Power Automate
Unanswered

Can the List Folder Action take a dynamic value for the Site Address Parameter?

(0) ShareShare
ReportReport
Posted on by

Having a very frustrating day of Flow building. I am using the List Folder action in an Apply to Each loop, but when I assign a dynamic value to the Site Address parameter, it doesn’t change. Each loop it keeps the original value.

 

If it only needs a site collection address, I can’t figure out how to enter the subsite. Including it in the Folder Identifier doesn’t work.

 

So no idea how to take a list of URLs and get the contents of those folders…

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

    Hi @Anonymous,

     

    Can you capture a screenshot of your whole flow so that I can understand you issue better and will try to reproduce your issue?

     

    Regards,

    Mona

  • Community Power Platform Member Profile Picture
    on at

    Sure,

     

    Basically I am grabbing a SharePoint list with a URLs for both the site and the folders I am interseted in. The site URLs are a number of subsites. When I call List Folder I want to pass in a new subsite and folder identifer, but while the Flow successfuly runs, it only takes the first value for the Site Address and just repeats itself, it doesn't get a new value for Site Address in the loop.

     

    Capture.JPG

  • v-monli-msft Profile Picture
    on at

    Hi @Anonymous,

     

    About compose concept in flow, you usually use it when you have a single value that you want to re-use many different times throughout your flow (for example, a single message that you want to reuse in several emails you send out). So the outputs from compose should always the same. And I think that is why it will repeats the same site address in List folder.

     

    Regards,

    Mona

  • DionGoile Profile Picture
    110 on at

    How often does the list of URL's change?

     

    You could add this to an external datasource easily (e.g SQL/Cosmo/Excel), then loop through each one using an "Apply to each" step.

     

    Then pass that variable into the rest of your Flow.

  • Community Power Platform Member Profile Picture
    on at

    @DionGoile that is what is not working. I am taking a list of URLs from a SharePoint list and then doing an Apply to Each, but it never takes a different URL. I just repeats over and over with the first URL. It don't see why looping over a SharePoint list would be different from an Excel sheet.

     

    I am also unclear how to pass the variable from the Apply to Each to the rest of the flow as I keep seeing contradictory statements about if that's even possible.

  • Community Power Platform Member Profile Picture
    on at

    @v-monli-msft that does not change the outcome. Compose was put in there because I thought maybe the issue was it wasn't taking a string value, but removing Compose produces the same behavior. It never goes through the list it just loops over and over on the first value passed to List Folder.

  • DionGoile Profile Picture
    110 on at
    Yes you are right sorry, must have read to quickly.

    Can you go into the history of your flow runs and take a screen shot of the data outputs? Let me know if you need assistance finding this.

    What can happen is that the entire data is output as one object, so there is only only Apply loop to complete hence the same result. If that is the case we should be able to use Parse JSON to fix your issue.
  • Community Power Platform Member Profile Picture
    on at

    @DionGoile Some of the outputs have some info from our tenant I don't want to share, but I can tell you it successfully pulls the data from the SharePoint list. On the output of the List Foder you can see it below minus a few ID tags:

     

    [
      {
    "Id": "%252fdocuments%252fArchive%252fTest%2bProposal%2bDocument%2b01.txt",
        "Name": "Test Proposal Document 01.txt",
        "DisplayName": "Test Proposal Document 01.txt",
        "Path": "/documents/Archive/Test Proposal Document 01.txt",
        "LastModified": "2017-05-18T02:00:20Z",
        "Size": 13,
        "MediaType": "text/plain",
        "IsFolder": false,
      }
    ]

     

    So while the Flow successfuly completes it's only reaching out to the first value, then completing without error.

  • DionGoile Profile Picture
    110 on at

    The fact you are getting one result is the reason this is not working, when I run it on a generic list I get multiple results. It should work fine.

     

    You may have encountered a bug, I would suggest (if you haven't already) create a new flow entirely and delete and reconnect your sharepoint connection in Flow. Also test with a different list.

     

    Otherwise one of the Microsoft team will be able to help you lodge a support case.

     

    Sorry I haven't been able to help more!

     

     

  • Community Power Platform Member Profile Picture
    on at

    @DionGoile Is the Site Address parameter you use for List Folder using a dynmaic value passsed from the previous step?

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 523 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 406 Moderator

#3
abm abm Profile Picture

abm abm 245 Most Valuable Professional

Last 30 days Overall leaderboard