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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
Anonymous
Not applicable

Highlight one row in a table based on selection from slicer

Hi All, I have the following table:

 

NameFeatureFeature 2

Tesla

14
Apple23
GameStop34
Microsoft45

 

I have a slicer that allows for company selection (but this slicer does not filter the table).

 

I want to highlight the row in the table associated with the selected company. In this case I will need to highlight Apples row.

 

 

I have tried creating a measure that computes a score based on the selected company, and then use conditional formating, but had no luck.

 

Any help is greeatly appreciated, 

 

Thanks

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous 

Build a measure as below.

Colormeasure = 
VAR _SELName = VALUES('Name'[Name])
RETURN
IF(ISFILTERED('Name'[Name]),IF(MAX('Table'[Name]) IN _SELName,"Red","Black"),"Black")

Add this measure into Font color in the Conditional formatting by Field Value.

1.png

Here you have three columns, you need to add this measure into all columns in Conditional formatting.

2.png

Result is as below.

3.png

When I select Apple, the Apple row will show Red Font color. If you don't want red color, you can change 'red' to other colors in measure.

For more details about conditional formatting: Use conditional formatting in tables

Currently, we can't use bold in conditional formatting.

Your demand is a good idea, while it is not supported to implement in Power BI currently.
You can vote up this idea for this function:additional font formatting (bold, italic, underline, etc)

Or you can submit a new idea to improve the Power BI.
It is a place for customers provide feedback about Microsoft Office products . What’s more, if a feedback is high voted there by other customers, it will be promising that Microsoft Product Team will take it into consideration when designing the next version in the future.

 

Best Regards,

Rico Zhou

 

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

4 REPLIES 4
juliavaranda
New Member

Hi Rico Zhou!

Could you please attach the .pbix file? It does not work for me.

Anonymous
Not applicable

Hi @Anonymous 

Build a measure as below.

Colormeasure = 
VAR _SELName = VALUES('Name'[Name])
RETURN
IF(ISFILTERED('Name'[Name]),IF(MAX('Table'[Name]) IN _SELName,"Red","Black"),"Black")

Add this measure into Font color in the Conditional formatting by Field Value.

1.png

Here you have three columns, you need to add this measure into all columns in Conditional formatting.

2.png

Result is as below.

3.png

When I select Apple, the Apple row will show Red Font color. If you don't want red color, you can change 'red' to other colors in measure.

For more details about conditional formatting: Use conditional formatting in tables

Currently, we can't use bold in conditional formatting.

Your demand is a good idea, while it is not supported to implement in Power BI currently.
You can vote up this idea for this function:additional font formatting (bold, italic, underline, etc)

Or you can submit a new idea to improve the Power BI.
It is a place for customers provide feedback about Microsoft Office products . What’s more, if a feedback is high voted there by other customers, it will be promising that Microsoft Product Team will take it into consideration when designing the next version in the future.

 

Best Regards,

Rico Zhou

 

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

Greg_Deckler
Community Champion
Community Champion

@Anonymous - I would use a separate, disconnected table for your slicer that way you could grab the MAX from each and compare them



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Can you explain how you would use the max function? I have the list of companies in a separate table so this idea seams viable. thanks.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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