Index through all files in a folder

I have a program that saves a bunch of excel files into a specific folder and I would like to index through all of the excel files within the folder and extract data from each is there a simple way to find the number of files within a folder and open them without knowing or referencing the exact name of the file?

(If not is there a way to actively rename files as they are saved from outlook email to a folder?)

Hi, do you want to open every file in the folder or only specific ones and if, by which criteria (date etc.) ?

to your second question… sure, the save attachments activity is able to do that.

When you save the File, add to for example, a SQLite Database, the information about file and then you can query that Database to know all about a file. The problem could be if a File is deleted or changed to other location, information in your database could be outdated.


Do you want to open any specific file with respective of extension? like (.xls,.csv file).
to read all the file from a directory you can use for each item of Directory.getFiles(path) in that you can filter the file based on your requirement