Reply
DesireeS
Frequent Visitor

Display dashed/dotted lines in legend

Please allow an option for the legend to display a line or a dot for colour (and dotted/dashed lines to match the line on the chart, like the figure below):

DesireeS_0-1687378922928.png

 

Context:

I would like to display four lines on my line chart:

  1. this year's rates for my Region,
  2. last year's rates for my Region,
  3. this year's rates for my Province/Territory/State, and
  4. last year's rates for my Province/Territory/State.

I would like last year's rates to be displayed as dotted lines, this year's rates to be displayed as solid lines, my Region's rates for both last year and this year to be the same colour, and the rates for my Province/Territory/State for both last year and this year to be the same colour. But if I were to do that right now in PBI, last year's and this year's rates would look the same in the legend because there is no differentiation between solid and dotted lines in the legend.

3 ACCEPTED SOLUTIONS
avatar user
Anonymous
Not applicable

Hi @DesireeS ,

Is this the outcome you want? 

JusticeJr_0-1687399872916.png

You can go to Legend and setting like this, then the legend will reflect the dotted/solid lines. 

JusticeJr_1-1687399923661.png

 

Best regards,

View solution in original post

danextian
Super User
Super User

hi @DesireeS 

 

The line chart visual has an option to chang the legend shape (marker and line) for each series.

danextian_0-1687399909332.png

 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

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


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

View solution in original post

Ritaf1983
Super User
Super User

Hi @DesireeS 
If I understand you correctly it is achievable.

Ritaf1983_0-1687399840019.png

you can format every line separately :

Ritaf1983_1-1687399888576.png

Legend will be referenced according to your formatting.

 

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

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

3 REPLIES 3
Ritaf1983
Super User
Super User

Hi @DesireeS 
If I understand you correctly it is achievable.

Ritaf1983_0-1687399840019.png

you can format every line separately :

Ritaf1983_1-1687399888576.png

Legend will be referenced according to your formatting.

 

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

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile
danextian
Super User
Super User

hi @DesireeS 

 

The line chart visual has an option to chang the legend shape (marker and line) for each series.

danextian_0-1687399909332.png

 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

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


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.
avatar user
Anonymous
Not applicable

Hi @DesireeS ,

Is this the outcome you want? 

JusticeJr_0-1687399872916.png

You can go to Legend and setting like this, then the legend will reflect the dotted/solid lines. 

JusticeJr_1-1687399923661.png

 

Best regards,

avatar user

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Feb2025 NL Carousel

Fabric Community Update - February 2025

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

Top Solution Authors (Last Month)
Top Kudoed Authors (Last Month)