Search code examples
sharepointazure-logic-apps

LogicApp reading from Sharepoint subfolders


Is it possible logicapp to read from the Sharepoint subfolder. Tried with the Get Files (Properties Only) still can't read files from the subfolders...

enter image description here


Solution

  • Below is something that you can follow to achieve your requirement.

    • I have used the same Get files (properties only) action as you have mentioned.

      enter image description here

    • In the next step Im trying to check if the iterated file is a folder and checking for a particular folder that I want the files to be retrieved.

      enter image description here

    • If the Condition is true, I'm trying to list all the files that are present in the folder and then retrieving the file. You can replace Get File metadata using path with Get file Content if you are trying to retrieve the file contents.

    RESULTS:

    Below is the file Structure in my Sharepoint

    ├───Documents
    ├───SampleText.txt
    ├───Folder1
        ├───aaa.txt
        ├───bbb.txt
        ├───SubFolder1
            ├───ccc.txt
            ├───ddd.txt
    

    enter image description here