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

Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.

Reply
sumneshnepalia
Frequent Visitor

Conditional formatting a multi line chart direct query

I have a multiline chart to show volumes by each date built on direct query dataset, requirement is to highlight the latest date line and make it look bigger or identifiable.

 

1 ACCEPTED SOLUTION

thanks @Anonymous .

I thought about that approach but got it working by sorting the dates ascending (to keep todays line on top) and using theme (Define 8 & 7 color as red and rest blue).
Since my data will always return 7 dates this solution works perfectly for now.

View solution in original post

6 REPLIES 6
Kedar_Pande
Super User
Super User

Please share a simplified version of your PBIX file (in English) without sensitive data. You can upload it to a public cloud service like OneDrive, Google Drive, or Dropbox and share the link. This will help in understanding your data structure and the issue, allowing for more precise guidance.

thanks @Kedar_Pande for reply, I have following line chart showing each line for multiple days of data 

X axis - timestamp of day

Y axis - total volumes

Legend - Date

sumneshnepalia_0-1729259268409.png

 

requirement is to highlight latest date's line to be more thicker and red, rest all lines should be more transperent and thin.

 

Data is in following tabular format

 

sumneshnepalia_1-1729260576820.png

 

Anonymous
Not applicable

Hi @sumneshnepalia ,

 

Unfortunately, conditional formatting is not available when there is a Legend field. However, you can manually change the format of the latest date line, for example, as below, I have bolded 18/10/2024 and changed the color to red.

vstephenmsft_0-1729581455053.png

 

 

Best Regards,

Stephen Tao

 

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

 

@Anonymous thanks for your reply.

 

Unfortunately it hardcodes these changes to date, so when the date changes it keeps the highlighting to 18/10/24 in your example, not to today's date

I have used theme as a workaround to make sure first line is always red, but cant change the thickness and its bit fiddly. 

Anonymous
Not applicable

Hi @sumneshnepalia ,

 

Another possible way to do this is to create multiple measures that return values with different timestamps, and then you can use conditional formatting.

This way is provided by PaulDBrown, in the post below.

Solved: Conditional Formatting a Line Chart in Power BI - Microsoft Fabric Community

If that still doesn't help, I suggest submitting an idea so that more people can vote for it:

Welcome to Microsoft Fabric Ideas

 

 

Best Regards,

Stephen Tao

 

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

 

thanks @Anonymous .

I thought about that approach but got it working by sorting the dates ascending (to keep todays line on top) and using theme (Define 8 & 7 color as red and rest blue).
Since my data will always return 7 dates this solution works perfectly for now.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.