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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
ashrafkotb
Helper I
Helper I

Legends show as separate lines

Hello,

 

I'm trying to plot a simple line chart with legends, pretty much like the below example:

https://www.youtube.com/watch?v=aOWyeIvpM2s

 

However, when I plot mine, the legends show as three separate lines, rather than colouring the same line with the different legend colours. Any clue what I might be doing wrong? 

 

C1.PNG

1 ACCEPTED SOLUTION
DanielPozo
Frequent Visitor

What happens is that in the example video, the categories occupy different years. Therefore, in the same year the Historical or Forecast category does not occur.

In your example the categories are present at the same time in some X-axis data, so when you place the legend you will see 3 different lines.

If you want to get the same video view, you must ensure that your data does not repeat the same categories for an X-axis data.

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@ashrafkotb , legend means three different lines.  It will look like one line only when it does have overlapping data

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
DanielPozo
Frequent Visitor

What happens is that in the example video, the categories occupy different years. Therefore, in the same year the Historical or Forecast category does not occur.

In your example the categories are present at the same time in some X-axis data, so when you place the legend you will see 3 different lines.

If you want to get the same video view, you must ensure that your data does not repeat the same categories for an X-axis data.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.