Monitor Only Files With Certain Extension in A Folder


Hello, I want to make a flow where if there is new .CSV file added in a folder, it will start a certain flow. I tried to use Monitor Event and File Change Trigger, but have no idea how to monitor only .csv files in the folder. Any advise how to do this?


You could try Directory.GetFiles(‘thePath’,’*.csv’) which will return you an array of strings and then, compare its length with 0 and check wether there are any csv files inside the directory or not.


Hello @Tiberiu_Niculescu, sorry for the late response.
Thank you for your suggestion. But I don’t see how to apply that in File Change Activity inside Monitor Events. Any way to do this with File Change Activity and Monitor Events?


It turns out I just need to set this in File Change Trigger Activity:

Path : folderIWantoToMonitorHere
FileName : "*.csv"
(suppose I want to monitor CSV files only).