cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
BiMK Helper II
Helper II

How to know if the user selected something on a slicer?

Hello everyone, 

 

I have a slicer on my report and a gauge that is filtered according to the selected value on the slicer. However if nothing is selected on the slicer then the value in the gauge correspodns to the first value on the slicer. I have a measure:

 

SelectedValue = FIRSTNONBLANK(Table[Column], Table[Column])

With this I get the selected value from the slicer. What I want is the following, if I don't select anything then the value on the gauge would be calculated for all the data. Here is an example

Screenshot_1.jpg

I want this measure to be calculated for both option 1 and option 2 if i have neither option selected. How can I do that? Any advice is welcomed.

Thanks 🙂

1 ACCEPTED SOLUTION

Accepted Solutions
BiMK Helper II
Helper II

Re: How to know if the user selected something on a slicer?

Thanks @v-shex-msft, but I used the ISFILTERED() function to see if I have anything selected on the slicer. 

View solution in original post

2 REPLIES 2
Community Support
Community Support

Re: How to know if the user selected something on a slicer?

Hi @BiMK,

 

>>I want this measure to be calculated for both option 1 and option 2 if i have neither option selected. 

You can try to use below formula:

 

Measure:

 

CalculatWithSlicer= Calculate(expression,AllSelect(Table[Column]))

 

 

Sample:

SumOfSlicer= Calculate(Sum(Table[Amount]),AllSelect(Table[Column]))

AvgOfSlicer= Calculate(Average(Table[Amount]),AllSelect(Table[Column]))

 

 

Regards,

Xiaoxin SHeng

Community Support Team _ Xiaoxin Sheng
If this post helps, please consider Accept it as the solution to help the other members find it more quickly
Learning resources: Power BI
BiMK Helper II
Helper II

Re: How to know if the user selected something on a slicer?

Thanks @v-shex-msft, but I used the ISFILTERED() function to see if I have anything selected on the slicer. 

View solution in original post

Helpful resources

Announcements
New Ranks Launched March 24th!

New Ranks Launched March 24th!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power BI Community!

‘Better Together’ Contest Finalists Announced!

‘Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

Arun 'Triple A' Event Video, Q&A, and Slides

Arun 'Triple A' Event Video, Q&A, and Slides

Missed the Arun 'Triple A' event or want to revisit it? We've got you covered! Check out the video, Q&A, and slides now.

Community Summit North America

Community Summit North America

Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors