cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
pfarley
Helper I
Helper I

Assigning Planer Labels through Power Automate

Hi everyone! First-time poster here.

 

I am using Power Automate in order to set up Teams -> Planners. I'm using these as task workflows. I set up all of the tasks in an Excel spreadsheet and then feed it into Sharepoint for the population of data in Planner.

Everything is working great except for one thing. After it finishes populating in Planner, I have to go through each task and manually add the Label. The labels are used to differentiate roles... ie. Marketing vs Operations.

The Labels are defined in the spreadsheet I am using. Is there a way to modify the Flow to allow Labels to be assigned through this task population, automation?


I can post pieces of my setup if it will help. Thanks!

13 REPLIES 13
ChristianAbata
Super User
Super User

no @pfarley  friend unfortunally is not possible this change needs to be manual



Did I answer your question? Please consider to Mark
my post as a solution! to guide others :winking_face:

Proud to be a Flownaut!


If you want you can follow me at www.christianabata.com Quieres contenido en español? Síguenos en Power Automate LA

Heh @pfarley  Somehow, I made it work. Newbie luck 😎

if(equals(item()?['CategoryColour'],'Pink'), True, False)

Hi there, I found this to work. I suppose you can then go into Planner and change the label name from 'Pink' to 'Name' once your flow has completed. Obviously I made a new column in the Excel table called 'Category Colour'. Unfortunately, Flow can't do the new colours, such as 'Bronze'.

 
bronze.pngcolours.png

 

pmadley
Regular Visitor

Success:

  1. I went into Planner and set up the 6 possible labels
  2. I added a new column 'Label' to the Excel table
  3. For 'Pink' I did: if(equals(item()?['Label'],'Moderate'), True, False)
    (Red = 'Critical or Serious', Yellow = 'Minor' etc...)

labels correct.png

@pmadley Thanks! Below is the general makeup of my flow.

pfarley_0-1620651516146.png


Where would you recommend placing the conditions? My excel sheet that is inserted into Sharepoint only has values in it. 

Would it be best to place the conditions here? If so, how?

pfarley_1-1620651599174.png

 

Zubaid
Regular Visitor

@pmadley If I already have labels created ie. each label is created for a specific team how do i assign my flow to that label without having to add the label manually to the team. I tried the above, but this does not add the label.

I tried this but somehow I cannot see the desired result like yours on the right hand side. It's blank for me 😞

claus8402
New Member

Any chance someone was able to get this working?  I tried the above, but I can't get it to create labels on the new task

Woah it feels like an eternity since I did this.

I recall that I had to set up the labels beforehand, then have a column in my excel file that had the label name (instead of colour). At the time it was restricted to the initial 6 colours Planner initially provided.

I'm currently doing a massive piece of ElasticSearch work so I can't commit to help atm I'm afraid.

Also... DISCLAIMER: I am not a 365 or Flow or Planner expert. I was just playing around. Don't rely on anything I say!

claus8402
New Member

Thanks for the reply.  It sounds like the integration between power automate and planner is still relatively new/underdevelopment.  

AllyWard
Frequent Visitor

I've got this working - though I only setup up coloured labels - doesn't change the name of them. But you only have to do that once, when the planner is complete.

I use excel as a source with boolean columns for each label I want to create. 

Planner labels.png

I initialise boolean variables first

planner initialise variable.png

then create conditions looking at the columns in my excel spreadsheet for whether each of the labels conditions is true or false and setting my variable true or false accordingly

Note that you need to look for True (not true or TRUE) in order for it to check it properly but set the variables with lower case

Conditions to set variablesConditions to set variables

 

then finally when I create the task I use the variable

Add the task using the variables for the labelsAdd the task using the variables for the labels

 

 

I've posted what I do - it's working for the 25 labels available now

FatherJB
Frequent Visitor

While you can't programmatically change the label names, assigning them is pretty easy.  For each object, you just have to do whatever logic you want to determine the label(s) color and then do one of these in each of the color options:

equals(variables('Label'), 'Pink')



FatherJB_1-1653309713609.png

 

If you want a list of labels, just make the variable an array, append each colors, and use:


contains(variables('Labels'), 'Pink')

 

Works like a charm. 

Yeah... that's basically what I did a year ago 😉

 

That said. It's useful to have consensus.

Helpful resources

Announcements
Register for a Free Workshop.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Users online (1,825)