cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
mmangiante
Level 8

Excel Get-Rows action issue with sending email

Hello,

 

I'm trying to extract information from an Excel file uploaded to SharePoint. I've seen that until now is not possible to do this directly but with a workaround, i.e., when I upload (create) the file in SharePoint, I copy it in OneDrive for Business and then use Get-Rows.

 

What I want to accomplish is send via email the values that I extract; I have a simple table of 1 row with 3 columns (now for testing, however only the columns may increase).

 

I've done a test with send an email with on field and initially it works, but when I tried to add the other fields I can't.

 

In the first image attached there is the flow that works; sorry for italian label, you can see that near the text "Cliente" there is the value that is in the Excel table and that is retrieved correctly.

flow get rows #1.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

After this, I tried to add the other 2 excel fields but when I try to insert the values I haven't the choice of these 2 on the dynamic list but only that of the "Current element" related to the "Apply to each":

flow get rows #2.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

How do you think I can resolve this issue? And why I have this issue in your opinion? I tried to create again the same flow but now, when I try to insert the value even for the first field, "Cliente", I have the same beahviour as the second image, so I can't even insert the first value as the first flow experiment.

 

--

Regards,

 

Marco

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Excel Get-Rows action issue with sending email

Hi @mmangiante,

 

Could you please share a bit more about your Excel table?

How do you get the first Cliente dynamic content of "Get rows" action within "Send an email" action?

 

I have made a test on my side and the issue is confirmed on my side, I could not reference the dynamic content of "Get rows" action within my "Send an email" action. My flow's configuration as below:9.JPG

 

Because I specify dynamic content within File Name field and custom value within Table Name field in "Get rows" action rather than specific File Name and Table Name, so the "Get rows" action could not retrieve proper values from Excel table dynamically.

 

If you want to reference the outputs of "Get rows" action, please take a try with the following workaround:11.JPG

Within Body field of "Send an email" action, type the following formula:

TaskName:

item()?['TaskName']

Panch in:

item()?['Punch_x0020_in']

Panch out:

item()?['Punch_x0020_out']

On your side, you should type the following formula to reference the dynamic content of "Get rows" action:

item()?['ColumnNameOfYourExcelTable']

Note: The 'TaskName', 'Panch in' and 'Panch out' are columns in my Excel table, if there is a space within the column name, please replace the space with '_x0020_' within above formula. In addition, there is only one row in my Excel table for testing.

 

The flow works successfully as below:

12.JPG

 

13.JPG

More details about using expression in flow actions, please check the following article:

Use expression in flow actions 

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Community Support Team
Community Support Team

Re: Excel Get-Rows action issue with sending email

Hi @mmangiante,

 

Could you please share a bit more about your Excel table?

How do you get the first Cliente dynamic content of "Get rows" action within "Send an email" action?

 

I have made a test on my side and the issue is confirmed on my side, I could not reference the dynamic content of "Get rows" action within my "Send an email" action. My flow's configuration as below:9.JPG

 

Because I specify dynamic content within File Name field and custom value within Table Name field in "Get rows" action rather than specific File Name and Table Name, so the "Get rows" action could not retrieve proper values from Excel table dynamically.

 

If you want to reference the outputs of "Get rows" action, please take a try with the following workaround:11.JPG

Within Body field of "Send an email" action, type the following formula:

TaskName:

item()?['TaskName']

Panch in:

item()?['Punch_x0020_in']

Panch out:

item()?['Punch_x0020_out']

On your side, you should type the following formula to reference the dynamic content of "Get rows" action:

item()?['ColumnNameOfYourExcelTable']

Note: The 'TaskName', 'Panch in' and 'Panch out' are columns in my Excel table, if there is a space within the column name, please replace the space with '_x0020_' within above formula. In addition, there is only one row in my Excel table for testing.

 

The flow works successfully as below:

12.JPG

 

13.JPG

More details about using expression in flow actions, please check the following article:

Use expression in flow actions 

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Highlighted
mmangiante
Level 8

Re: Excel Get-Rows action issue with sending email

Hello @v-xida-msft

 

thanks for your support. With your help I resolved and I understand what was my issue (that finally was not an issue but my inattention): when the first time I applied the item()?['MyItem'] I entered the flow and have seen the expression green coloured like Excel; I then entered the flow 10 days after and I don't remember the expression applied, so I write it again but it was purple and not green so I supposed that I used another expression.

 

--

Regards,

 

Marco Mangiante

Helpful resources

Announcements
firstImage

New Ranks and Rank Icons in April

Read the announcement for more information!

firstImage

Better Together Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (3,825)