It looks like you are running into the issue I did when following the instructions for this flow where each email would receive an email for every task. On the first page in this thread my posts layout the issue and then i have one going over my complete setup in flow, have you tried the settings from those?
I read it and it sounded to me like you were getting an email for each item. My emails contain a list of multiple items (as intended) but emails themselves are being send multiple times. So if I have two items on the list, I will receive two emails that each contain both items. Do you think your solution would work for my issue too?
@DanFFSLA you are not using DistinctEmailArray and compose needs to be removed, See my screenshots below:
1. Initialize variable called 'DistinctEmailArrray' of type array. In the value, use following:
2. Inside your filter array action , change existing expression on the right side of equal to to "
3. Send an email action: Change TO formula to
@DanFFSLA yes I was getting an multiple emails for each item which would contain all of the items (it would just iterate through the number of items) but in my next response I solved what the issue is with the orginal post. Please see my two replies.
(Link above doesn't jump to message but it is message 13 in this thread)
Also it looks like @dmistry is pointing out the issue that would of been found in my post as well
@DanFFSLA I was in the same position as yours, lol. I have been in situations where I would have given up on many flows that I had started working on but the flow community is always there to help us so never lost hope and thanks to Microsoft for setting up a platform like this. Many thanks to @ZachRoberts for his work on the revised solution. Cheers, good to hear that it helped you @DanFFSLA.
Thanks @dmistry, after much struggling, the solution was merely to modify my Sharepoint List such that my Person/Group field allowed multiple values.
Since it looked like alot of people are stumbling across this forum post I did a write up on how to set this up and to get it to work on my website check it out if you would like.
I tried all the above options but could not fix the below error:
Unable to process template language expressions for action 'Apply_to_each' at line '1' and column '2032': 'The template language function 'first' expects its parameter be an array or a string. The provided value is of type 'Null'. Please see https://aka.ms/logicexpressions#first for usage details.'.
Any other options:
Attached are the screenshots. The Sharepoint list has four columns and every column has data. Let me know if you need any additional information.
Thanks for the info.
Now I am just assuming here but is the screenshot of your list with the test data in it the one you are using or was setup as an example? My question here is are you using the 'People' column for your "Assigned To" field?
My Assigned To field is setup as below
@ZachRoberts Thanks for the response. Yes, that is correct. I am getting the error with the same data. The 'AssignedTo' column has the same properties as yours. Also, all the other columns are removed from the list except these four which we see in my screenshot.
@BB9 Can you send screen shots of the errors you get when you are testing your flow? It might be helpful to see at what step your flow is breaking, can you also expand the other formulas you have entered in your flow?
I think i see the issue. on your first apply you need to gather the email addresses and add them to your array like the below screenshot from my flow.
In your screenshot below you are missing this step. So you need to add append to array variable and make sure the apply to each output is set to the value you get from the get items.
Speakers, submit your sessions now! Call for speakers ends Feb. 10!
We've updated and improved the layout and uploading format of the Power Automate Cookbook!
Fill out a quick form to claim your user group badge now!
We've given our badges an overhaul and also added some brand new ones!
Learn how to build the business apps that you need.
Find out where you can attend!
Watch & learn from the Power Automate Community Video Gallery!