LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Embedding Excel worksheets into Word

Hi all, i have created 2 worksheets in an Excel document using the report generation toolkit.  I then save this file.

 

I then open a new 'word' report (pointing to the saved excel file) and use the "word insert object" to embed the excel worksheets into Word but it is only putting the 2nd worksheet in?

How do i gain control of which worksheets i want to insert so that i can get both.  Perhaps a property in "automation open"?

 

Regards,

0 Kudos
Message 1 of 5
(3,276 Views)

Hi Grant

 

I will be looking into this problem for you and helping you find a solution for your system. As I understand this issue, you have used the report generation toolkit to create a report in excel, but you would now like to access elements of this report in a word file. Please correct me if I have misunderstood.

 

I have been looking at some examples which may help you, but I am unsure which level you have got to, would it be possible to have a copy of your code to look through, so I can make some suggestions that you can implement without too much difficulty? If it is not possible to post the code online, please let me know, but it would be very useful if you could.

 

Thank you

Stephanie L
Applications Engineer
National Instruments UK and Ireland
0 Kudos
Message 2 of 5
(3,252 Views)

Hi Stephanie, i have resolved this problem by keeping both Excel and Word reports open in parallel and using the 'Excel Get Worksheet.vi' to select the particular worksheet number at the specific place in my Word report.

Thanks anyway.

0 Kudos
Message 3 of 5
(3,241 Views)

That's great to hear, you may like to add an example vi of this for other people to have access to.

Good luck with the rest of your development.

Thanks

Stephanie L
Applications Engineer
National Instruments UK and Ireland
0 Kudos
Message 4 of 5
(3,232 Views)

Hi Stephanie, i have attached a .jpg of the code.

 

This shows the file path of the Excel document along with the 2 reports. (1 being Word and the other being Excel).  I used "Excel Get Worksheet.vi" to select the particular Excel worksheet and then "Word Insert Object.vi" and "Word Easy Text" to insert and add text to my Word report.

 

0 Kudos
Message 5 of 5
(3,169 Views)