Skip to main content

Notifications

Community site session details

Community site session details

Session Id : JqSvj6abuzyfhDJ2K4sDXP
Power Automate - General Discussion
Answered

Populate a Microsoft Word template with dynamicschema and repeat contentcontrol

Like (0) ShareShare
ReportReport
Posted on 8 Nov 2022 14:25:10 by 105

I have to fill a word template with data and I use Populate a Microsoft Word template with dynamicfileschema
but a field is of type "repeating content" and instead of inserting the correct values it shows the JSON (if I don't use dynamicfileschema it works perfectly)

i have to use dynamicfileschema because the template file can change slightly and i have too many templates to manage them individually

 

paronchi_0-1667917213514.png

varMyTable is an JSON Array

the results is

 

paronchi_2-1667917436590.png

 

 

 

  • Anderrj2 Profile Picture
    25 on 08 Jun 2023 at 18:57:10
    Re: Populate a Microsoft Word template with dynamicschema and repeat contentcontrol

    I want to thank you for this! This JSON was messing me up so badly, it being that I had quotes when I didn't need them is silly.

     

    It finally got it!

     

    I'm using an ArcGIS Survey123 trigger, making a report, then adding a table of data that I pulled from another hosted feature layer to combine things into a single document.

  • Verified answer
    paronchi Profile Picture
    105 on 09 Nov 2022 at 10:57:02
    Re: Populate a Microsoft Word template with dynamicschema and repeat contentcontrol

    yes, yes, yes, solved, it was enough to remove the "

    example

    {
    "355479380": "variables('myvar')",
    "504866188": variables('mytable')
    }

     

    355479380 normal word control

    504866188 repeat word control

    'myTable' JSON Array

  • paronchi Profile Picture
    105 on 09 Nov 2022 at 09:59:17
    Re: Populate a Microsoft Word template with dynamicschema and repeat contentcontrol

    thank's, i tried but it doesn't work 😭

  • grantjenkins Profile Picture
    11,059 Super User 2025 Season 1 on 09 Nov 2022 at 08:52:09
    Re: Populate a Microsoft Word template with dynamicschema and repeat contentcontrol

    I think it's displaying it as plain text because it doesn't recognise it as JSON. Can you pass your variable into a json expression before you add it to the dynamic schema and see if that works.

     

    json(variables('output'))

     

  • paronchi Profile Picture
    105 on 09 Nov 2022 at 06:37:21
    Re: Populate a Microsoft Word template with dynamicschema and repeat contentcontrol

    the example uses the "Populate a Microsoft Word template" connector in the "standard" way, and this way it works for me too, but I have to (want) to use it with dynamicfileschema to avoid making a case for each template slightly different (I have 1000 to manage) and using dynamicfileschema as in the examples found, only the standard controls work and not the type "repeating content"

  • SudeepGhatakNZ Profile Picture
    14,297 Most Valuable Professional on 08 Nov 2022 at 21:39:31
    Re: Populate a Microsoft Word template with dynamicschema and repeat contentcontrol

    @paronchi , 

    Have you looked at this article? 

     

    https://www.bythedevs.com/post/how-to-populate-a-word-template-with-repeating-control

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 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,645 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,997 Most Valuable Professional

Leaderboard