Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi All,
Need your help here.
Can we set the Force selection and Max number of selections in Power BI Slicer.
If No, is there any custom visual, which can provide both functionalities.
Many thanks.
@Anonymous you can try forced selection using "ChicletSlicer" visual, go to https://app.powerbi.com/visuals/ and download "ChicletSlicer" visual. Once you download it select visualisation under settings change Forced option to On
As far as I know there is no such direct option to restrict slicer values selection. Alternatively based on the count of selected values in slicer you show or hide some warning message to user saying that they have selected more values than the allowed slicers values.
Hi @itsmebvk
Many thanks for your reply.
I need both the features 1. Force Selection 2. Max. limit of selecion in one visual. Your idea is good to add warning messages. I can try with that. Would be grateful, if you can tell me how we can set up the warning msgs in Power BI.
Thanks again.
@Anonymous Please follow below steps
1)Create a table report with desired columns
2)Create a slicer on desired columns
3)Create a measure "Selected Count"using following code
Selected Count = if(ISFILTERED(Sheet1[Color]),CALCULATE(SUMX(VALUES(Sheet1[Color]),1)),0)
4)Create one more measure "Message" using following code
Message = if([Selected Count]>5,"Please Select Only 5 Values"," ") & if([Selected Count]=0,"Please Select A Values"," ")
5)Add Message column to a new table, hide header of the table and borders
Now when you select more that 5 values in slicer it will display warning message, I have also added optional message when nothing is selected in slicer. PFA PBIX for your reference.
Please mark post as resloved this solution helps.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
57 |
User | Count |
---|---|
146 | |
110 | |
93 | |
84 | |
67 |