Skip to main content

Notifications

Community site session details

Community site session details

Session Id : kjV831wJ8iQ+A3CCWTOWjk
Power Automate - General Discussion
Answered

No attachment in my Power Automate Flow

Like (0) ShareShare
ReportReport
Posted on 14 Nov 2021 08:21:51 by 16

Hi All,

 

I have created a Power Automate flow with the trigger (when a file is created property only) that should send an email with the attachments, the flow is running except I have no attachment in the file and I don't have the attachment(s), I don't see where the problem is, if you can help me

 

power automate 1.jpgpower automate 2.jpgPower automate 3.jpg

  • Ellis Karim Profile Picture
    10,940 Super User 2025 Season 1 on 31 Aug 2023 at 22:47:52
    Re: No attachment in my Power Automate Flow

    Hi @Lovemolecule_9 ,

     

    Here are some things to try:

     

    (1) You can use the Filter Array action to select just the files from the List Folder action (we want to ignore any  folders):

    ekarim2020_0-1693521760986.png

     

    (2) Use the Body of the Filter Array action in the Apply to Each loop:

     

    ekarim2020_2-1693521870177.png

     

    (3) Send an email only if the array variable arrAttachments is not empty:

    ekarim2020_3-1693521905032.png

     


    Ellis
    ____________________________________
    If I have answered your question, please mark the post as ☑️ Solved.
    If you like my response, please give it a Thumbs Up.
    My Blog Site

  • Lovemolecule_9 Profile Picture
    14 on 31 Aug 2023 at 07:18:42
    Re: No attachment in my Power Automate Flow

    Hi again Ellis

    Thanks for your reply, 

     

    This is what I made, a quick point, the folder that I put a file to run the flows, is different from the folder that attachment/s are there, because first I need to be sure if the correct file is in the folder.

     

    in summary, place if trigger file is different from places of attachment/s (list folder)

     

    Screen for Flow.png

    and last part, 

    Lovemolecule_9_0-1693467133898.png

     

    I used Cancel to avoid sending more than one mail, because of apply to each, was sending email for each try if I had more than one attachment,

     

    Thanks again, 

    Have a great day,

    Mohammad

  • Ellis Karim Profile Picture
    10,940 Super User 2025 Season 1 on 30 Aug 2023 at 23:02:44
    Re: No attachment in my Power Automate Flow

    Hi @Lovemolecule_9 ,

     

    Sorry, I am having difficulty understanding how the flow is supposed to work.

     

    Can you please show me the details of the When a File is created action, the List folder action and the Get File content action.

     

    For example:

    ekarim2020_0-1693436506659.png

     


    Ellis
    ____________________________________
    If I have answered your question, please mark the post as ☑️ Solved.
    If you like my response, please give it a Thumbs Up.
    My Blog Site

     

  • Lovemolecule_9 Profile Picture
    14 on 30 Aug 2023 at 09:26:03
    Re: No attachment in my Power Automate Flow

    Hi again Ellis,

    Thanks for your quick replies.

     

    Sure, as I need to send emails to more than 40 contractors, do the below actions:

     

    1 - I need to check the files before the email is sent. Therefore I asked Flow to start if I put a file in a separate folder than the place the files are there,

    2 - Flow will get file/s inside each folder (there are 40 folders), 

    3 - Flow check them if they contain specific word/s (Contractor name),

    4 - Flow attach the files and send email, 

     

    What were the challenges:

     

    1 - Sometimes I had no file/s but Flow was sending email even if there is no attachment,

    2 - Follow was sending multiple emails if I had more than one attachment, 

     

    Also for your question; Body (get file content by using path) is created when I used "Get file Content and then when I used "Path";

     

     

    Lovemolecule_9_0-1693387447858.png

     

    I appreciate your attention and look forward for any suggestion, 

     

    Stay safe

    Mohammad

     

  • Ellis Karim Profile Picture
    10,940 Super User 2025 Season 1 on 30 Aug 2023 at 07:29:43
    Re: No attachment in my Power Automate Flow

    Hi @Lovemolecule_9 ,

     

    Can you explain in simple terms what your flow is designed to do, and then how the flow works?

     

    Please also tell me where the Body property is coming from in your flow:

     

    ekarim2020_0-1693380110139.png

    And

    ekarim2020_1-1693380125431.png

     

    Also note that the "When a file is created in a folder (depreciated)" action used in your flow. "(depreciated)" means that this action is no longer recommended for use. Use a recommended replacement action to ensure compatibility and continued support. For example, you could use the When a file is created (properties only): 

     

    ekarim2020_2-1693380232128.png

     


    Ellis
    ____________________________________
    If I have answered your question, please mark the post as ☑️ Solved.
    If you like my response, please give it a Thumbs Up.
    My Blog Site

  • Lovemolecule_9 Profile Picture
    14 on 30 Aug 2023 at 06:58:19
    Re: No attachment in my Power Automate Flow

    Hi Ellis

    Good morning, 

     

    Thanks for your reply; please see what I made last, 

     

    Lovemolecule_9_0-1693378485863.pngLovemolecule_9_1-1693378507168.png

     

    Somehow, this flow works, but I was forced to use cancel flow, which I believe is not a proper solution; I made some criteria to prevent some mistakes:

     

    1- Flow should send if file name/s doesn't contain the specific word (Company names)

    2 - Flow should not send an email if the folder is empty.

     

    Thanks again

    Have a nice day,

    Mohammad

  • Ellis Karim Profile Picture
    10,940 Super User 2025 Season 1 on 24 Aug 2023 at 20:31:07
    Re: No attachment in my Power Automate Flow

    Please share your flow.

     


    Ellis
    ____________________________________
    If I have answered your question, please mark the post as ☑️ Solved.
    If you like my response, please give it a Thumbs Up.
    My Blog Site

  • Lovemolecule_9 Profile Picture
    14 on 21 Aug 2023 at 13:03:32
    Re: No attachment in my Power Automate Flow

    I added a condition after getting file content; but it is still sending emails if there is no attachment.

  • Lovemolecule_9 Profile Picture
    14 on 21 Aug 2023 at 12:44:22
    Re: No attachment in my Power Automate Flow

    Hi Ekarim,

    Good afternoon, 

     

    I created a Flow like the mentioned one, but due to check the file, I didn't use same folder to send email if there is any new file, I used another folder, my issue is like this:

     

    Flow sends email if there is no attachment, but I don't want the flow to send the email, if there is no attachment, can you give me a solution?

     

    Lovemolecule_9_0-1692621785600.png

     

    Thanks in advance, 

    Have a nice day

    Mohammad

     

     

     

  • Fantoma25 Profile Picture
    16 on 07 Dec 2021 at 09:56:54
    Re: No attachment in my Power Automate Flow

    Hi Ellis,

     

    thanks a lot for your time and your support, it is working perfectly,

     

    Regards

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

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Power Automate - General Discussion

#1
rpersad Profile Picture

rpersad 16

#2
David_MA Profile Picture

David_MA 10 Super User 2025 Season 1

#3
Michael E. Gernaey Profile Picture

Michael E. Gernaey 8 Super User 2025 Season 1

Overall leaderboard