Forum Discussion

pfr1992's avatar
pfr1992
Advocate II
9 years ago

Disable All selection in slicer

 

Hello everyone , I have a slicer that selects several regions , however ,
not like he selecionasse all regions , because each region has a different value and it is not possible to make an average with these values. There is a function in the slicer to disable the " select all " ??
thank you

8 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    pfr1992 I don't know if I'm answering your question, but "Select All" is a formatting option that you should have the ability to turn on and off...

    • pfr1992's avatar
      pfr1992
      Advocate II

      @Eno1978 wrote:

      pfr1992 I don't know if I'm answering your question, but "Select All" is a formatting option that you should have the ability to turn on and off...

       


      The problem is this : When you have an option selected it shows me the values ​​of this region that I am selecting . As I show in the image below ...




       

       

       

      when I double click this option clears and ends up showing all the regions . Each region has a specific value , then I can not select all at once because then the graph will be wrong. There is an option that exiting this function to " select all " ?? thank you



       

       

         

      • Anonymous's avatar
        Anonymous
        Not applicable

        pfr1992 I think I understand now. The default behaviour is to show everything. What you want is to only show the visuals if you have selected a value in the slicer. I don't have a direct example, but this post is a similiar question. The solution will require some modification or development in DAX.

  • v-haibl-msft's avatar
    v-haibl-msft
    Microsoft Employee

    pfr1992

     

    I’m not sure your ultimate goal. But if you only want to get the average value for selected Gerencia, you can add an average line in Analytics pane as below.

     

     

    Best Regards,

    Herbert

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hello,

       

      There is no option to disable "Select all" or to have a force selection in a slicer. But i have developed a workaround to hide all the data. Create 2 measures as below.

       

      Valid_selection = if(HASONEVALUE(Slicer_attribute), "", "Error: Select a Single value")

      Valid_selection_numeric = if(HASONEVALUE(Slicer_attribute), 1, 0)

       

      Pull the first measure into a card, which will be blank when a single value is selected and will throw an error message when it is more than one/All.

       

      Second measure to be added as a visual level filter, add Valid_selection_numeric = 1 as visual level filter on all the visuals. Which means, the data will be displayed only when a single value is selected. 

      Nothing but hiding the data for all.

       

      Let me know if you have any questions.

       

      Hope this helps.

       

      • vgk_17's avatar
        vgk_17
        Frequent Visitor

        Anonymous This does not work when we have slicer as slider (when we are displaying it as between). Can you please suggest something that works on slider as well.

  • Hey,

    You can try to disable the "select all" by creating two measures.

    Like this:- 

    Measure_1 = if(HASONEVALUE(column_name), "", "’ Select a Single value")

    Measure_2 = if(HASONEVALUE(column_name), 1, 0)

     

    This will help you to get the desired output.

    Hope this will help.