Forum Discussion

Rejaul84's avatar
Rejaul84
Frequent Visitor
2 years ago
Solved

Slicer setting to deselect all

Hi I would like to know if its possible to have a slicer to not show the results if nothing is selected. i.e if I search for ticket numbers using the search function within the slicer the table of da...
  • Ritaf1983's avatar
    2 years ago

    Hi Rejaul84 
    You can modify this functionality with Dax.

    The slicer's values should be in a separate table:

    Then you can create a measure that tests if there is some filter applied on a slicer's table :

    Selection test = if(ISFILTERED('Slicer'[Category]),1,0)
    This measure can be used to filter other visuals 

    You also can create a dynamic title based on this measure to guide the user:

    Title = if ([Selection test]=1, "Category by value", "Please select category")

    Pbix is attached

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

  • Rejaul84's avatar
    2 years ago

    Hi Ritaf1983 

     

    Thanks for the help. I was able to do this but not exactly the way you have shown but I have taken the dynamic title tip, as this is good from a user perspective.

     

    I ended up doing the following;

    Add new measure

    FilterCheck = INT(ISFILTERED('TableA'[Category]))

     

    This worked for me without the need to have another table for the slicer.