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 / Forms Attachment to E-...
Power Automate
Unanswered

Forms Attachment to E-Mail

(0) ShareShare
ReportReport
Posted on by 20

I am trying to get an attachment from Microsoft Forms and send it to an e-mail by using the "Switch" function. However, I am not able to initialize a variable within the Switch function and I did it outside of it and it is still not working. What would be the solution in this case?

MMPowerAutomate_0-1668714061464.png

 

Categories:
  • annajhaveri Profile Picture
    8,531 Most Valuable Professional on at

    @MMPowerAutomate  you need to initialize variable before the Switch action. I presume that you might be creating array variable, then append file content to array variable in apply to each loop as shown below. Then use array variable in attachment parameter of Send Email action.

    annajhaveri_0-1668763382013.png

     

  • v-dezhili-msft Profile Picture
    Microsoft Employee on at

    Hi @MMPowerAutomate ,

    Do you want to put the file uploaded to the MS form into the attachment of the email?
    Please try this way.

    vdezhilimsft_0-1668764330254.png

     

    vdezhilimsft_1-1668764330255.png

     

     

    vdezhilimsft_2-1668764330255.png

     

    vdezhilimsft_3-1668764330256.png

     

    vdezhilimsft_4-1668764330257.png

     

    vdezhilimsft_5-1668764330258.png

     

    Best Regards,

    Dezhi

  • MMPowerAutomate Profile Picture
    20 on at

    @v-dezhili-msft ,
    It worked, but the file I get is not in a PDF form and it looks a bit strange. Is that normal?

    MMPowerAutomate_1-1668868644116.png

     

  • MMPowerAutomate Profile Picture
    20 on at

    Hi @annajhaveri ,

     

    Thank you for your response. Could you please show what I should put in Apply for Each?

    MMPowerAutomate_0-1668866931303.png

     

  • v-dezhili-msft Profile Picture
    Microsoft Employee on at

    Hi @MMPowerAutomate ,

    Could you please show me the filename of the outputted array?

    vdezhilimsft_4-1668764330257.png

    Best Regards,

    Dezhi

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 302 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 263

#3
Henil Profile Picture

Henil 115

Last 30 days Overall leaderboard