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

Level up your Power BI skills this month - build one visual each week and tell better stories with data! Get started

Reply
QMSAutomation
Regular Visitor

Conditional Formatting line chart line colours based on a column

Hello,

 

I am attempting to display a line chart that has groups of lines with the same colour. This is being done for patients in a clinical trial therefore I cant devulge the types of data being displayed but I can explain the relationships: 

Table:

QMSAutomation_0-1676580353983.png

Column 1 is in the legend (patient), column 2 is the patients data (Y axis), column 3 is the testing days (X axis), column 4 is the grouping each subject belongs to. 

I want to display each subjects data, but want the line colours to be displayed by grouping in column 4, is this possible?

 

Current line chart: 

QMSAutomation_2-1676580795167.png

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@QMSAutomation , You can choose a color for the line. but conditional formatting is not supported. We can format marker, but that only when we have one measure and no legend 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@QMSAutomation , You can choose a color for the line. but conditional formatting is not supported. We can format marker, but that only when we have one measure and no legend 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thanks for the response, not having the legend in the graph won't show my data correctly, so I'll have to stick with the current colours and use a slicer to display only the groups when selected. Thanks!

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.