web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / how to check if files ...
Power Automate
Unanswered

how to check if files name contains a value or file exist

(0) ShareShare
ReportReport
Posted on by

 

Hi,

I have about 500 word file in a folder, and I want to amend some content then save as pdf format with date added in file name into another folder.

The thing is the above flow takes too long so it may be interrupted sometime.

I do not know how to continue the loop if its interrupted, so what I currently come up with is to compare the file names to skip the loop.

I have tried the following 2 method,

1. is to extract the word file names, then run the loop to see if the pdf file names contains the word file name, which does not work

2. is to extract the word file names, then use if file %current file%-date.pdf exists, which still not work

 

Please help. Thanks.

 

Screenshot 2022-12-14 122110.png

Screenshot 2022-12-14 121527.png

I have the same question (0)
  • XRQ57 Profile Picture
    206 on at

    Hi,

    if the comparison is too long, you can use powerquery to check your files and building 2 lists for PAD.

  • VJR Profile Picture
    7,635 on at

    The "If file exists" should work in this case without a loop.

    Can you make sure the correct text is compared...like spaces etc in the actual file name and in the variable you are trying to compare eg; %current file%-date.pdf

    A good way is to print the complete variable value in a Display box and then use that variable for the comparison.

     

    Also if possible share the actual file name.

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 592

#2
Valantis Profile Picture

Valantis 340

#3
11manish Profile Picture

11manish 284

Last 30 days Overall leaderboard