cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
solisruj
Level: Powered On

Conditional File Extension filtering

Hi there everyone, 

 

I built a flow for document approval. I built the flow to be able to filter file types based on file extensions and convert/save copies in .pdf format. I tested it and it seemed to work flawlessly. The flow was able to filter out both ".docx" and ".xlsx" files and produce .pdf copies of both file types. I wanted to test it today for a demonstration, so I did a trial run on two ".docx" files; however, the workflow failed. 

Conditional.PNG

 

 

 

I opened it in advance mode to get an idea of what is going on: 

 

@contains(body('Get_file_properties')?['{FilenameWithExtension}'], 'docx')

 

To me, the above seems like it would work, but I am not sure if it is actually pulling the information I want. Would it be possible to modify/implement (or code) the method so that it pulls the filename extensions only? The idea would be for @contains() to make a comparison of the file extensions with a modified/implemented segment of code. 

 

 

***** Turns out the workflow works. I just made a mistake in an earlier step that produced files without extensions.   

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Conditional File Extension filtering

Hi @  solisruj,

 

 

Have your problem solved?

Have you  made a mistake in an earlier step that produced files without extensions?

 

Please click "Accept as Solution" so that this thread will be marked for other users to easily identify if your problem is solved.

 

Regards,
Alice Zhang

View solution in original post

1 REPLY 1
Community Support Team
Community Support Team

Re: Conditional File Extension filtering

Hi @  solisruj,

 

 

Have your problem solved?

Have you  made a mistake in an earlier step that produced files without extensions?

 

Please click "Accept as Solution" so that this thread will be marked for other users to easily identify if your problem is solved.

 

Regards,
Alice Zhang

View solution in original post

Helpful resources

Announcements
firstImage

Power Platform Online Conference

Join us for the first ever Power Platform Online Conference!

firstImage

Coming Soon: T-shirt Design Contest

Keep your eyes open for our upcoming T-shirt design contest!

firstImage

Incoming: New and improved badges!

Look out for new contribution recognition badges coming SOON!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Top Solution Authors
Top Kudoed Authors
Users online (6,402)