I have a collection using
Planner.ListMyPlansV2().value
for a combobox. However, I want to show more information per plan with the Teams (groupid) they are associated with. Look something like below:
Team
Plan
I have tried the following:
Collect(MyTeamsPlansGalleryItems, MicrosoftTeams.GetAllTeams().value, Planner.ListGroupPlans(Lookup(MicrosoftTeams.GetAllTeams(id).value).value)
To then use the "displayName" and "planName" for the ComboBox fields. Any help would be appreciated. thnx
Solved! Go to Solution.
Hi @simondpalmer ,
Do you want a table with the value of group name and plan name?
If so, you just need to make a little change.
Try this formula:
ClearCollect(test1,If(!IsEmpty(MicrosoftTeams.GetAllTeams().value),ForAll(MicrosoftTeams.GetAllTeams().value,AddColumns(Planner.ListGroupPlans(id).value,"groupname",displayName))));
Clear(test2);ForAll(test1,Collect(test2,Value))
//Using AddColumn function to add a column with the value of displayName that MicrosoftTeams.GetAllTeams().value returns, which is group name.
Best regards,
Hi @simondpalmer ,
Do you want to list multiple group plans based on selected group?
If so, I've made a similar test for your reference:
1)connect your app with microsoft teams, planner
2)insert a combo box to list all the teams that you belongs to (combo box1)
set the combo box's Items:
MicrosoftTeams.GetAllTeams().value
set the combo box's OnChange:
ClearCollect(test1,If(!IsBlank(ComboBox1.SelectedItems.id),ForAll(ComboBox1.SelectedItems,Planner.ListGroupPlans(id))).value);Clear(test2);ForAll(test1,Collect(test2,value))
//test1 will be nested tables, the part2 formula is used to collect all the value of nested tables
3)insert another combo box to list all the plans based on the selected groups
set the combo box's Items:
test2
Then combo box2 will list all the plans based on the selected groups that you select in combo box1.
If you not want to select groups, just want to list all the plans that your groups have, you could set the screen's OnVisible to this:
ClearCollect(test1,If(!IsEmpty(MicrosoftTeams.GetAllTeams().value),ForAll(MicrosoftTeams.GetAllTeams().value,Planner.ListGroupPlans(id))).value);
Clear(test2);ForAll(test1,Collect(test2,value))
Then set the combo box's Items to : test2
Best regards,
Thank you that is great I used the last option. Though I now have the id and the title of the plan coming into test2 how can I get also the MicrosoftTeams.GetAllTeams fields as well? So I can have a combobox showing:
Team1
Plan1
Team1
Plan2
Team2
Plan1
etc..
Hi @simondpalmer ,
Do you want a table with the value of group name and plan name?
If so, you just need to make a little change.
Try this formula:
ClearCollect(test1,If(!IsEmpty(MicrosoftTeams.GetAllTeams().value),ForAll(MicrosoftTeams.GetAllTeams().value,AddColumns(Planner.ListGroupPlans(id).value,"groupname",displayName))));
Clear(test2);ForAll(test1,Collect(test2,Value))
//Using AddColumn function to add a column with the value of displayName that MicrosoftTeams.GetAllTeams().value returns, which is group name.
Best regards,
User | Count |
---|---|
255 | |
106 | |
85 | |
51 | |
43 |