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

Line chart based on measures - How can I make the legend respond on the choice

I made a line chart based on measures, with a slicer that also shows the data based on measures.

 

For example, if I choose Aantallen, this is what you will see:

 

M_MELLEMA_0-1721287962065.png

 

If I were to click on Bedragen, you would get a different overview. That works fine.

What I can't get is that the Legend also changes based on the choice you make.

When I choose Aantallen, I only want to see the legend of Aantallen and not the percentages and bedragen.

 

The legend is based on the measures I placed on the y-axis.

M_MELLEMA_1-1721287986735.png

How can I make sure that in the legend, which is based on the measures in the y-axis, I only see the legend that belongs to the choice I make?

1 ACCEPTED SOLUTION
M_MELLEMA
Frequent Visitor

I've fixed it on a differt way with bookmarks.

View solution in original post

4 REPLIES 4
M_MELLEMA
Frequent Visitor

I've fixed it on a differt way with bookmarks.

Ashish_Mathur
Super User
Super User

Hi,

Share the download link of the PBI file.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Anonymous
Not applicable

Hi @M_MELLEMA 

 

You'll need to put the category field in the "legend" box, I've made an example PBIX to help you understand.

vjialongymsft_0-1721353005010.png
vjialongymsft_1-1721353012616.png

 



 

 

 

 

 

 

Best Regards,

Jayleny

 

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

Hi Jayleny,

 

The category is a created table:

M_MELLEMA_0-1721375590253.png

I've tried to put Weergave to the legend field, but I can't put it there. 

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.