cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Using expression in reference to array or excel value data to populate lable/Colour fields in Planner 'Create a task' if match return 'True'

Hello,

 

Status:

- In Planner I have Labels setup as such:  Red = Toast , Green = Bread, Blue= Burnt  (examples)

- I have a flow functioning that uses 'List rows present in table' and using output value 'Create a task' and 'Update task details'

            It is working great and populates Planner tasks as desired in reference to an Excel table.

 

Issue:

I am seeking to use the dropdown 'Enter custom value' for each colours field in the 'Create a task'.  Using an array that took the cell data from excel, or in reference to the value data from my ingested Excel table, I would like the expression to match and return 'true' based on a manual entry in the expression and against the cell in the tables row.

 

As such:

Expression in Red field of 'Create a task' will look for 'Toast' in the corresponding row of the table, it may have Toast, Bread, no data, or Burnt.  Only Toast will return true.

Expression in Green field of 'Create a task' will look for ' Bread' in the corresponding row of the table, only 'Bread' will = true.

 

And so on.

 

If this expression, or expression along with creating an array ahead of it would provide some functionality to the labels / colours section I think it could help answer a few other posts I came across when looking for help.

 

I tip my hat to the programmers, two weeks into Power Automate and I have not yet got an array to work correctly, and my expression string skill is junk.

 

Any and all help welcome,  Thank you!

 

Cheers,

NK

2 REPLIES 2
Anonymous
Not applicable

UPDATE:

 

So I have managed to put together the following expression, with no errors when I save and run the flow.

 

if(equals(outputs('List_rows_present_in_a_table')?['Name'], 'My Name'), True, False)

 

It returns False no matter what.

 

The drop down for the label section is - Yes, No, Enter custom value   ( and the default text says True if task has category)

 

Using in the label/colour area as such:

label expression.PNG

 

Each expression for yellow, green, blue, has a different entry in the expression for 'My Name' .

 

I require that when each label/colour matches its corresponding name from the tables Name column, it returns a True value to the field.

 

 

Any and all help with this concept is much appricated.

 

Thank you,

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

Helpful resources

Announcements
2022 Release Wave 1 760x460.png

2022 Release Wave 1 Plan

Power Platform release plan for the 2022 release wave 1 describes all new features releasing from April 2022 through September 2022.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

User Group Leader Meeting January 768x460.png

Calling all User Group Leaders!

Don't miss the User Group Leader meetings on January, 24th & 25th, 2022.

Top Solution Authors
Top Kudoed Authors
Users online (1,809)