Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
BenWade
New Member

Assign colors to a column depending on a priority column

Hi everyone! When I choose a particular project manager I want Project codes to be green, red or yellow depending on the budget or appointment columns(for that I can add a slicer to distinguish between budget and appointment). How to achieve it? Any ideas?

 

BenWade_2-1673106339469.png

 

1 ACCEPTED SOLUTION
v-zhangti
Community Support
Community Support

Hi, @BenWade 

 

Copy 2 identical tables first in Power Query. Table 1 leaves the Budget Closure column and Table 2 retains the Appointment Closure column.

vzhangti_0-1673247677889.png

Transform—Unpivot Column:

vzhangti_1-1673247790446.pngvzhangti_2-1673247802123.png

Append two tables.

vzhangti_3-1673247871508.png

Rename the column Slicer and Color.

Measure:

Color Measure = IF(SELECTEDVALUE(Append1[Slicer])<>BLANK(),SELECTEDVALUE(Append1[Color]))

vzhangti_4-1673248239112.png

Result:

vzhangti_5-1673248269874.pngvzhangti_6-1673248284317.png

Is this the result you expect?

 

Best Regards,

Community Support Team _Charlotte

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-zhangti
Community Support
Community Support

Hi, @BenWade 

 

Copy 2 identical tables first in Power Query. Table 1 leaves the Budget Closure column and Table 2 retains the Appointment Closure column.

vzhangti_0-1673247677889.png

Transform—Unpivot Column:

vzhangti_1-1673247790446.pngvzhangti_2-1673247802123.png

Append two tables.

vzhangti_3-1673247871508.png

Rename the column Slicer and Color.

Measure:

Color Measure = IF(SELECTEDVALUE(Append1[Slicer])<>BLANK(),SELECTEDVALUE(Append1[Color]))

vzhangti_4-1673248239112.png

Result:

vzhangti_5-1673248269874.pngvzhangti_6-1673248284317.png

Is this the result you expect?

 

Best Regards,

Community Support Team _Charlotte

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Sept PBI Carousel

Power BI Monthly Update - September 2024

Check out the September 2024 Power BI update to learn about new features.

September Hackathon Carousel

Microsoft Fabric & AI Learning Hackathon

Learn from experts, get hands-on experience, and win awesome prizes.

Sept NL Carousel

Fabric Community Update - September 2024

Find out what's new and trending in the Fabric Community.