cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Chris22
Frequent Visitor

Get contents from Excel Table and paste into new excel sheet

Hello,

 

I have a spreadsheet in sharepoint with a number of tables.

On a weekly basis I'd like to email the contents of a specific table to a specific group of people. I don't want to email the entire spreadsheet as most of the information is not relvent. I'd like the flow to copy the table, create a new s/s then send this new s/s as a link or attachment.

 

I can get most of the flow apart from getting the contents from the table and adding it to a new document. 

Thoughts?

 

1 REPLY 1
sumurthy
Microsoft
Microsoft

You can use Office Scripts to achieve this. 

You will need two scripts: 

1. First script extracts the data fields that you need from the master Excel file. You can see beginning part of this video to see how to extract and pass data from one script to another: https://www.youtube.com/watch?v=dVwqBf483qo&feature=youtu.be&ab_channel=SudhiMurthy

 

2. On a newly created Excel file, you can run the next Office Script to create a new table. 

You can checkout this article to see how to create a new table - 

1. first you have to update the range with the data coming from step-1. 

2. add a table on the range that you just updated. 

https://docs.microsoft.com/en-us/office/dev/scripts/develop/scripting-fundamentals#ranges

 

You can then email the new Excel file's link to recipients. 

 

Please message if you need help.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power Automate Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Top Solution Authors
Users online (1,588)