Hi,
As the name implies, I'm looking for a flow that will delete files/folders that are older than 7 days.
Any help would be greatly appreciated
I find it still can delete files only, not folders. Anyone resolved this issue?
Did you ever get this working? I'm attempting to do the same thing
When I run the flow I get the error:
Unable to process template language expressions for action 'Condition' at line '1' and column '2225': 'The template language function 'greaterOrEquals' expects all of its parameters to be either integer or decimal numbers. Found invalid parameter types: 'Boolean'.'.
Hi,
I still want to build this flow, any help please?
I get this error due to being a folder
Hi @Anonymous ,
According to your description, you want to delete files/folders that are older than 7 days in OneDrive via MS Flow.
I have made a test on my side, please take a try with the following workaround:
The expression of Compose is: addDays(body('Get_file_metadata')?['LastModified'],7,'yyyy-MM-dd'), add 7 days on the last modified date.
The expression of Condition is: greaterOrEquals(outputs('Compose'),utcNow('yyyy-MM-dd')), judge whether the files are older than 7 days.
Best Regards,
Zhongys
Michael E. Gernaey
497
Super User 2025 Season 1
David_MA
436
Super User 2025 Season 1
Riyaz_riz11
244
Super User 2025 Season 1