cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Khan321
Helper III
Helper III

populate a word template

Hej 

Khan321_0-1656261309955.png

 

I am trying to make a flow "Which takes data form excel and populates it on the world file.

I have tried alot but no luck.  

Please take a look of the flow i made.

 

Thanks in Advance

Najib

 

Khan321_1-1656261391067.png

 

Khan321_3-1656261488901.png

Khan321_4-1656261514294.png

 

 

 

 

17 REPLIES 17
MarconettiMarco
Super User
Super User

Hello @Khan321 ,

do you want to generate a Word doc for each table row? In this case you don't need to create a variable and append to array.

After populating a Word Template you should create a file in OneDrive or SharePoint with the Content equal to the Body got from the "Populate a Microsoft Word Template" action.

 

What is the error? Can you share it?

 

BR,

Marco

Khan321
Helper III
Helper III

@MarconettiMarco Thank you for your message.

 

let me explain a bit more. 

Vi receive 200 to 500 invoices in excel each weeks.   

I want to populate every single invoice in the word template and convert it to pdf and send it til the person or company.  

 

I will try to do it as you said og will let you know 🙂

thank you once again 🙂

 

her is the excel file with invoice  

Khan321_0-1656410857128.png

 

 

Naji

 

 

 

Khan321
Helper III
Helper III

Hi again @MarconettiMarco 🙂

 

i did as you said but i cannot see a body for the Content field?

may be i am doing something wrong.  Please take a look of following pics. 

 

   

Khan321_4-1656411943381.png

Khan321_5-1656411963570.png

Khan321_6-1656411994995.png

Khan321_7-1656412019727.png

Thank you for your time .

                                                   

 

 

 

 

 

 

 

 

 

Hi @Khan321

please in the dynamics content search in the Populate a Microsoft Word Template

MarconettiMarco_0-1656412582300.png

 

 

BR,

Marco

Khan321
Helper III
Helper III

Hi igen @MarconettiMarco 

i am really sorry for stupid question. I am not able to find the dynamic content search.

 

Could you please help with that?

where can i find it?

 

Hi @Khan321 ,

np!

 

In the File Content field, search for "Microsoft" into the dynamics value like the following screen:

 

MarconettiMarco_0-1656413308341.png

 

BR,

Marco

Khan321
Helper III
Helper III

@MarconettiMarco 

for me it says The content of the file not insert  a dynamic value as i can see on your picture. 

Khan321_0-1656414457920.png

 

@Khan321 click on the "Add dynamic content" link and search for "Microsoft Word document".

 

BR,

Marco

Khan321
Helper III
Helper III

@MarconettiMarco  nothing appears there. 🙂

 

Khan321_0-1656416586307.png

thank you for all your time

 

BR 

Naji

Khan321
Helper III
Helper III

@MarconettiMarco   Sorry my bad. it creates word file now but only for the first row.

 

i should have created the create file in side the apply to each but i tried to create it out side of apply to each as "New Step".

it creates world file now but only for the first row.  it does not create word file for all the rows in side excel file.

Please take a look of the pictures

 

Khan321_0-1656419395208.png

 

BR

 

 

ok,

in the last run how many excel rows have you got?

Khan321
Helper III
Helper III

@MarconettiMarco i got one row means one invoice populated on the word file.  

each row contains of one invoice.

ok @Khan321 ,

if from the "List rows present in a table" action you got only one row, it means the flow is working properly.

 

BR,

Marco

Khan321
Helper III
Helper III

but i have 3 rows in that file which is in the "List rows present in a table".

will it not populate more than 1 row at a time?

for example i have 3 test rows in the excel file but i get populated only the first row not  the 2 others.

 

Once again thank you for all help and time 🙂

@Khan321 maybe the file name is always the same, and the file are overwritten?

 

Anyhow can your run the flow and share the screen in regards of the apply to each action?

BR,

Marco

Khan321
Helper III
Helper III

@MarconettiMarco 

 

it says file does not exists.

Khan321_0-1656421220335.png

Khan321_1-1656421346788.png

 

Khan321
Helper III
Helper III

@MarconettiMarco  Hi again Marco 🙂

Thank you for you help on the teams. 

 

now it works fine until populating and creating word files for every row in the excel but when i try to convert it to pdf it makes 3 pdf files(there are 3 rows in excel now) , each with 36 pages 🙂

 

could you please help with that?

 

Khan321_0-1656426415089.png

 

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Users online (1,983)