cancel
Showing results for 
Search instead for 
Did you mean: 

How to Filter by File type from a Collection?

JohnreyGabarra1
Level 2

Hello, Everyone.

Here's what I have so far.

I have an Action that takes Mail ID from the Email to get Attachments.

Some Attachments have Images (img) in it.

547.png


I want to filter out a set of File types but mainly Excel files (xls, xlsm, xlsx, etc.)

But I either don't get results when I straight out write the name I want to filter ("Result.xlsm") or use a Wildcard ("*.xlsm")

548.png
Thank you.



------------------------------
Johnrey Gabarra
------------------------------
4 REPLIES 4

EmersonF
MVP
Hi, nin the filter collection try using the expression "[Name] like '%xlsm'", you needed to pass the column name in the filter

------------------------------
Emerson Ferreira
Sr Business Analyst
Avanade Brasil
+55 (081) 98886-9544
If my answer helped you? Mark as useful!
------------------------------
Sr Cons at Avanade Brazil

jhogelp
Level 8
Hi, Jhonrey.

I hope you are well, I am attaching a reference image of how you have to place the filter to help you filter the items you need.
In the filter collection field you will use the expression: "[Name] like '%.xls*'" output collections files (xls, xlsm, xlsx, etc.).
537.png

I hope I've helped.

Regards


------------------------------
Jhogel Ponne
Senior RPA
Ernst & Young
America/Panama
------------------------------

AndreyKudinov
Level 10
Filter collection or loop collection, then use decision InStr(coll.name,".xls")>0

------------------------------
Andrey Kudinov
Project Manager
MobileTelesystems PJSC
Europe/Moscow
------------------------------

EVIPUTI
MVP
You can either filter your collection by using "[Name] like '%.xls*'" to get only email attachments or you can also delete those which are images .png in your collection .

------------------------------
------------------------------
Vipul Tiwari
Senior Process Simplification and Optimization Designer(Solutions Architect)
Fidelity International
------------------------------
------------------------------
------------------------------ Vipul Tiwari Senior Process Simplification Developer Amazon ------------------------------