cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MS2
Level: Powered On

List Sharepoint folder

Hi,

 

What's the "right way" to get the contents of a Sharepoint folder when you have the path as a string in a variable? The List folder action takes the folder id, not the folder path and the Get files doesn't take a path either (I have the folder path as text in two variables).

 

As mentioned here https://powerusers.microsoft.com/t5/Using-Flows/List-folder-sharepoint-using-Microsoft-Flow/td-p/302... I can replace(concat(string1, string2), '/', '%252f') but that's an ugly hack:

  • Unmaintainable if the Flow team decides to change the internal format of the Folder Id
  • Begs the question: are there any other characters apart from '/' that needs to be encoded? Which ones?

Thanks,

MS

2 REPLIES 2
Community Support Team
Community Support Team

Re: List Sharepoint folder

Hi @MS2,

 

Could you please share a screenshot of your flow's configuration?

Could you please show a bit more about your two variables that you mentioned?

 

Thanks for your feedback, I could not find any document about encoding the special character (such as, '/', '_','-', etc.) within File Identifier or Folder Identifier currently. If I find the document related to it, I would reply here.

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
MS2
Level: Powered On

Re: List Sharepoint folder

Hi Kris, I have adopted the replace(concat(string1, string2), '/', '%252f') until I find some other solution. Is there somewhere I could read about which variable formats that are planned as persistent between flow generations. If the official stance is that the Folder Id/File identifier will forever be the encoded path then the above approach is ok (but still ugly). So there are no other encodings apart from the /?

 

Screenshot.jpg

 

The full expression above goes 

replace(concat('/contact/', string(items('Apply_to_each')?['ATSDocumentsFolder'])),'/','%252f')

 

Best regards,

MS

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Watch the event on demand for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020.

thirdimage

Flow Community User Group Member Badge

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

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Users Online
Currently online: 110 members 2,952 guests
Please welcome our newest community members: