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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Populate a Microsoft w...
Power Automate
Unanswered

Populate a Microsoft word template based on Form responses where there are multiple answers for a question

(0) ShareShare
ReportReport
Posted on by 8

Hi, looking for a small bit of help, please.

 

I'm populating a Word document using Power Automate when a response is submitted to a form.

 

Most of the questions are yes/no answers, and one of them will pull through some text. An example expression is: 

 

if(equals(outputs('Get_response_details')?['body/r3be654137aae4fde8510a4bb370f4523'],'Yes'),'We would recommend the preparation of a shareholder’s agreement.','')
 
The problem I'm having is where a questions can have multiple answers e.g. A/B/C where any number of the three can be selected: A, A and B, B and C etc
Aidan_O_0-1690199076466.png

 

I tried putting an expression in for each answer, but nothing is coming through. If I turn multiple answers off, it works, but then I can only get one text answer, when I want it to also be able to do two or three
Aidan_O_1-1690199172548.png

 

How can I pull through the three different bits of text depending on the different amount of answers?

Categories:
I have the same question (0)
  • Verified answer
    v-xiaochen-msft Profile Picture
    on at

    Hi @Aidan_O ,

     

    Please try to use contains instead of using equals, something like:

    if(contains(outputs('Get_response_details')?['body/r3be654137aae4fde8510a4bb370f4523'],'A'),'Answer for A','')

    if(contains(outputs('Get_response_details')?['body/r3be654137aae4fde8510a4bb370f4523'],'B'),'Answer for B','')

    if(contains(outputs('Get_response_details')?['body/r3be654137aae4fde8510a4bb370f4523'],'C'),'Answer for C','')

     

    Best Regards,

    Wearsky

  • Aidan_O Profile Picture
    8 on at

    That works perfectly, thank you.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard