Getting the excel file in Sharepoint

Hi ,
I am using microsoft office 365 package in my code where I am using Find files and folder activity.
The output of this activity is getting me the folder name also.
But I just need the names of excel files(all formats i.e. xlsx,xlsm etc.)or text files present there.
What should I give in the query part of Find files and Folder activity to get the desired output??

you need to do the exact search, put the necessary query to be able to find the file (folder1/folder2/ “make the query here”) and have the output

Hi @Kunal_Jain

Can you try this-


  • "path/to/folder/" represents the path to the folder you want to search in. Replace it with the actual path to your target folder.

  • "*.{xlsx,xlsm,txt}" specifies the file filters. The asterisk (*) is a wildcard that matches any characters in the file name, and the curly braces ({}) enclose the file extensions you want to include. In this case, it includes xlsx, xlsm, and txt extensions. You can add or remove file extensions as per your requirements.


To retrieve only the names of Excel files (xlsx, xlsm, etc.) or text files from a specific folder using the “Find Files and Folders” activity in UiPath, you can use the following query in the “Search in” field:


Replace “Path\to\folder” with the actual path to the folder where you want to search for files. This query will search for files with the extensions “.xlsx”, “.xlsm”, and “.txt” within the specified folder and its subfolders.

By using this query, the output of the “Find Files and Folders” activity will only contain the names of Excel files and text files, excluding any other file types.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.