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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

Displaying the selected line in a graph

Hello,

 

When I select an option from the legend of a graph, I want to display only the selected line in the graph and all other lines should be invisible.

 

Can anyone help me with this, please?

1 ACCEPTED SOLUTION
PaulusD
Resolver II
Resolver II

Add the values that you have in the legend to a slicer next to the graph. by default a slicer will filter out the rest of the values 😊.

View solution in original post

6 REPLIES 6
Anonymous
Not applicable

Hello @PaulusD,

 

I've tried to add the legend values to a slicer as you suggested, but I'm unable to add them to the slicer may be because they are measure values.

Is there any other way to acheive this?

Not sure you can place measure values in a slicer... If the result is numerical you could try something like this:

Power BI - Filter by a Measure in a Slicer - YouTube

 

Otherwise try making a calculated column instead of a measure and use the column in a slicer. That way you can also group the values if you want.

Anonymous
Not applicable

@PaulusD 

I want ot get the values as a list to choose from not as group of values, is this possible to do?

If you calculate the values in a calculated column instead of a measure, it should work just fine  :).

Anonymous
Not applicable

Thanks I'll try this

PaulusD
Resolver II
Resolver II

Add the values that you have in the legend to a slicer next to the graph. by default a slicer will filter out the rest of the values 😊.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors