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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
pabloignacio123
Regular Visitor

How to enable sorting by colour indicators in a table without labels

I’m working on a Power BI table visual that uses conditional formatting (colour indicators such as green, red, yellow) to show status for various fields (e.g. Usage Rate, Below Average Last 3 Months, etc.). The colours are working well, but I’ve noticed that unless I display a label or value in the field, users can't sort the column by clicking on it.

Is there a way to allow users to sort the table by these columns (based on the logic behind the colours) without having to show a text or numeric label? Ideally, I want the table to remain clean, showing only the colour indicators, but still be sortable.

Any suggestions would be greatly appreciated!

grid example.png

Thanks in advance.
Pablo

1 ACCEPTED SOLUTION

@dm-p 

Thanks for your prompt response

Hi @pabloignacio123 ,

Thank you for the detailed explanation earlier  it was really helpful.

I’ve implemented the logic as discussed and have uploaded a sample PBIX file for your review. Could you please take a look and let us know if it’s working as expected, or if there’s anything that might need adjustment?

Looking forward to your feedback.

Best regards,

Lakshmi


Create a calculated column  Status_Code based on Usage Range

Status_Code =
SWITCH (
TRUE (),
[Usage_Range] >= 0.8, "V",
[Usage_Range] >= 0.5, "A",
"R")

vlgarikapat_1-1752830311294.png

View solution in original post

7 REPLIES 7
v-lgarikapat
Community Support
Community Support

Hi @pabloignacio123 ,

Thanks for reaching out to the Microsoft fabric community forum.

To better understand the issue and build the appropriate logic, it would be very helpful if you could share some sample data that fully represents the problem or question you're referring to.

Kindly ensure the data is:

In a usable format (e.g., Excel or CSV), rather than a screenshot

Free of any sensitive or unrelated information

Looking forward to your response.

Best regards,
Lakshmi Narayana

Dear Lakshmi,

Thank you for your prompt response and for your willingness to help.

To clarify my question: I am working with a table visual in Power BI where I use conditional formatting (specifically colour indicators—green, yellow, and red) to reflect statuses such as “Usage Rate” or “Performance over the Last 3 Months.” These indicators are based on DAX measures that evaluate specific thresholds or trends.

The colours are displaying correctly; however, I’ve noticed that unless I show a numeric or text label within the cell, users are unable to sort the column by clicking on the header. My aim is to keep the table visually clean—showing only the coloured indicator (for example, a coloured circle or background)—but still allow sorting based on the logic that determines the colour.

Would you happen to know if there is a way to enable sorting in this context, perhaps by linking the conditional formatting logic to a hidden or supporting field?

Please let me know if it would be helpful to share a sample file. I’m happy to prepare one accordingly.

Best regards,
Pablo

@dm-p 

Thanks for your prompt response

Hi @pabloignacio123 ,

Thank you for the detailed explanation earlier  it was really helpful.

I’ve implemented the logic as discussed and have uploaded a sample PBIX file for your review. Could you please take a look and let us know if it’s working as expected, or if there’s anything that might need adjustment?

Looking forward to your feedback.

Best regards,

Lakshmi


Create a calculated column  Status_Code based on Usage Range

Status_Code =
SWITCH (
TRUE (),
[Usage_Range] >= 0.8, "V",
[Usage_Range] >= 0.5, "A",
"R")

vlgarikapat_1-1752830311294.png

Hi Lakshmi,

That’s exactly what I needed — thank you very much for implementing the logic and for sharing the PBIX file.

I’ll review it shortly and get back to you with any observations or suggestions, if necessary.

Best regards,
Pablo

Hi @pabloignacio123 ,

You're very welcome  I'm glad to hear it met your needs.

Please feel free to reach out with any feedback or suggestions once you've had a chance to review the file. I'm happy to make any adjustments if needed.

Looking forward to hearing your thoughts.

Best regards,
Lakshmi

Hi @pabloignacio123,

 

Have you considered setting conditional formatting on both the font color and the background color? Having a useful value in the cell (albeit colored out) can help from an accessibility perspective if you have users who use a screen reader, but will still provide the cosmetic effect you want.

 

Regards,

 

Daniel





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!


On how to ask a technical question, if you really want an answer (courtesy of SQLBI)




Yes, I have considered applying conditional formatting to both the font colour and the background colour. Including a meaningful value in the cell — even if it’s visually hidden by using the same font and background colour — can indeed be beneficial for accessibility, especially for users relying on screen readers.

It's a clever approach that maintains both functionality and visual cleanliness. I’ll explore this further to ensure it aligns with our design goals while supporting usability.

Thanks for the suggestion!

Best regards,
Pablo

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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