cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper II
Helper II

Delete images if file size is less than certain size

Hello, 


I am building a flow that puts images in a document library. Up to 40 images might be coming in at once. The flow already gets the file properties so I know I have access to look at the size of each photo. Is there a way I can specify flow to delete all images if they are under a certain file size, say 1MB?

 

Appreciate any insight on this issue!!

 

Thanks!

1 REPLY 1
Impactful Individual
Impactful Individual

Add a Filter array action. The input of the Filter array is the list of files coming in (from where you haven't said). The filter will be File Size is greater than 1024000 bytes I don't know what your incoming data looks like so I can't be more specific but it'll be item()?['Size'] if your file size column is called Size.

 

Anyway, you can then use the output of that Filter array action in an Apply to each to create the destination files.

Helpful resources

Announcements
Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

New Super Users

Meet the Power Automate Super Users!

Many congratulations to the Season 1 2021 Flownaut Crew!

New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Users online (27,857)