Skip to main content

Notifications

Community site session details
Power Automate - Building Flows
Answered

Excel (Businness) table manipulations and Sharepoint Copy file /Create file

Like (0) ShareShare
ReportReport
Posted on 18 Apr 2018 05:03:23 by 14,756

Hi!

I am thinking on a Flow that will copy an already existing excel file from a Sharepoint Library (you can see it as a "template", even though it is .xlsx) and store it on the same Sharepoint Library. The next step I wanted to achieve was to add a new row to a specific Table belonging to the new file.

However, according to Microsoft Flow Team feedback, choosing a dynamic content in the "File" field to select a file is not supported in Microsoft flow "Excel (Business)" connector currently. If you want to vote such idea, please visit https://powerusers.microsoft.com/t5/Flow-Ideas/Dynamic-content-in-File-amp-Table-inputs-Excel-Business/idi-p/107822#M6939

 

So, I am trying to find a workaround for this limitation. I am playing with the opposite approach: I add a new new row to a specific Table belonging to the original file (the "template"), then I create a new file with the contents of the "template" file and store it on the same Sharepoint Library, finally remove the new row from the "template" file.

 

The problem with this potential workaround is, once I open the new file,  the new row is not there. It seems Flow makes the copy of the "template file" taking as reference its contents before adding the new row.

 

Is this the expected behaviour? Is this a bug? Can you think on any other workaround? Suggestions, welcome

Thank you in advance!

 

Screenshot of the "template" excel file:

CopyExcel.png

 

The Flow I have tested as a potential workaround:

CopyExcel2.png

 

Inputs chosen in "Excel (Business) Add row into a table" action block

CopyExcel3.png

 

Inputs chosen in both "Sharepoint Create File" action block and "Copy File" action block. Please note I have tested two potential workarounds once I add the new row to the "Template" file:

1.- create a new file with the contents of the "template" file and store it on the same Sharepoint Library, finally remove the new row from the "template" file ("true branch of the condition)

2.- copy the "template" file and store the new file on the same Sharepoint Library, finally remove the new row from the "template" file.

No matter the potential workaround I test, the result is not the expected one: i.e. the new file does not contain the new row

CopyExcel4.png

 

The content of the new file: no matter I test branch True or False (I convert the condition from "is equal to" into "is not equal to"), the new file does not contain the new row

CopyExcel5.png

 "List rows present in a table" and "List rows present in a table 2" allows me to verify the new row is added to the "template" file. I've also verified it by moving the terminate action block just after "Excel (Business) Add row into a table" and this before "List rows present in a table 2".

  • efialttes Profile Picture
    14,756 on 07 May 2018 at 16:08:23
    Re: Excel (Businness) table manipulations and Sharepoint Copy file /Create file

    Thanks for your suggestion, Kris!

  • Verified answer
    v-xida-msft Profile Picture
    on 20 Apr 2018 at 01:38:00
    Re: Excel (Businness) table manipulations and Sharepoint Copy file /Create file

    Hi @efialttes,

     

    I have made a test on my side and confirmed the issue. It seems that the flow create a new file with the contents of the "template" file before adding a new row into the "template" file.

     

    I have made a test on my side and please take a try with the following workaround as an alternative solution:

    • Add a proper trigger, here I use Flow Button trigger.
    • Add a "Add a row into a table" action, specify Location, Document Library, File and Table.
    • Add a "Delay" action, Count set to 1 and Unit set to Minute.
    • Add a "Get file content" action of SharePoint connector, specify Site Address and File identifier field set to the "template" file (source file).
    • Add a "Create file" action, specify Site Address and Folder Path. File Name set to Employees(Copy).xlsx, File Content field set to File Content dynamic content of the "Get file content" action.
    • Add a "Delete a row" action, specify Location, Document Library, File (the "template" file) , Table, Key Column and Key Value.

    Image reference:1.JPG

     

    2.JPG

    The flow works successfully as below:3.JPG

     

     

    The "template" file read as below:5.JPG

    The new file read as below:4.JPG

     

     

    Best regards,

    Kris

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Power Automate - Building Flows

#1
stampcoin Profile Picture

stampcoin 87

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 70 Super User 2025 Season 1

#3
David_MA Profile Picture

David_MA 48 Super User 2025 Season 1

Overall leaderboard
Loading started
Loading started