Hi, I am pretty new to Flows, so I will try to describe what I am trying to accomplish as best as I can.. I have a sharePoint list with columns like this:
The important columns to take note are Team Name, and CF Group
Team Name - is a single line of text (Title/describes the team name)
CF Group - is a person column, it can take multiple selection (person 1, person 2, etc), and its people only (members of the team)
What I would like to do is group the SharePoint list that I have, by the Team Name, and send the list associated to the members of the team in one email on a weekly basis. I know how to set up the flow to run on a weekly basis, but everything after that is difficult..
So the email should look like this:
To: CF Group (their email addresses of the team)
Subject: TBD
Body:
Sharepoint list grouped filtered for the given team name
There doesn't seem to be an easy way to do this, unfortunately. I looked around on the forum, but can't find anything like this one. Please let me know if you can help, thank you.
Solved! Go to Solution.
Hi @imadorkous,
You could initialize a string variable action to hold these Emails in a CF Group. Then use the Append to string variable action to put the Email and character ";" into the variable, then you can put it into the Send Email action *To field; Then if you want to get the list group by the Team name, you could create the second Get items with Filter query, TeamName eq 'dynamic content', then create an HTML table as the Email body.
After that, you should set the variable to null to let the variable could hold these Emails of the next CF Group.
Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @imadorkous,
Thanks for your reply, if the two fields' people numbers are dynamic, you could initialize two string variables to hold theirs displayname, and initialize an array variable to structure the final table named WholeEntity:
Then put the items into the Apply to each action, then put the array of Assign RAIL and Sales engineer into two individual apply to each actions to get their display name:
Then add the Append to array variable action as below, put the two display name variable into the array member, after you should empty the two display name variable for next item:
After all, create HTML table by using the WholeEntity variable:
Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @imadorkous,
You could initialize a string variable action to hold these Emails in a CF Group. Then use the Append to string variable action to put the Email and character ";" into the variable, then you can put it into the Send Email action *To field; Then if you want to get the list group by the Team name, you could create the second Get items with Filter query, TeamName eq 'dynamic content', then create an HTML table as the Email body.
After that, you should set the variable to null to let the variable could hold these Emails of the next CF Group.
Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thank you, @v-litu-msft,
This worked great! I'm almost at the end of the tunnel, but I am stuck getting some of the values for some fields:
It is coming out like this:
How can I get the values (display names) of the fields Assign RAIL Item to: and Sales Engineer to just show, and how do I only get the text on Action Items field to just show?
Hi @imadorkous,
Are the numbers of Assign RAIL and Sales Engineer always fixed? Always 2 and 1?
If they are fixed, it is simple to do, you could use the expression:
Assign RAIL field:
item()?['Assign_RAIL_Item_to'][0]['DisplayName'];item()?['Assign_RAIL_Item_to'][1]['DisplayName']
Sales Engineer field:
item()?['Sales_Engineer'][0]['DisplayName']
Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
no, it would be dynamic; It can be one, two or sometimes even three names in either of the fields. Let me know if there is something else I could do.
Do you know if there is anything that can be done on the Action Items field?
Hi @imadorkous,
Thanks for your reply, if the two fields' people numbers are dynamic, you could initialize two string variables to hold theirs displayname, and initialize an array variable to structure the final table named WholeEntity:
Then put the items into the Apply to each action, then put the array of Assign RAIL and Sales engineer into two individual apply to each actions to get their display name:
Then add the Append to array variable action as below, put the two display name variable into the array member, after you should empty the two display name variable for next item:
After all, create HTML table by using the WholeEntity variable:
Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
This worked out great, the last piece that I am trying to figure out is how to get just the text out of the action items field (multi-line field). This is what it currently looks like right now:
There are two records, and the first record should say "Update is provided!", and the second record should say "Testing testing"
Hi @imadorkous,
Using the Html to text action could do it, please have a try:
Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
87 | |
43 | |
21 | |
18 | |
15 |
User | Count |
---|---|
130 | |
47 | |
42 | |
35 | |
28 |