Forum Discussion
reset slicer without bookmark
Hello Fellow Daxers
Is it possible to reset a slicer using a Dax measure and not a bookmark? I have a matrix, filtered by providers. If just two providers are set--I have a slicer that presents some nice options to look at various pieces of a venn diagram. (ALL, BOTH, 1 only, 2 only). But if a user selects three or 50 providers, the slicer should basically just show ALL and no other options.
What happens, is if the last slicer selection is BOTH...and the user picks more providers--I can get the slicer to show one item, but can't get the slicer to reset so that it will always show ALL (or disappear for that matter.)
Here's the measure I use to filter to get it to show just one item if more than 2 providers: I was hoping the filter in the Calculate would reset the table and therefore the slicer. I know, that doesn't make sense...but what does?
NotHeadToHeadFilter = IF([DestProvCountForMatrix] <> 2, CALCULATE([DestProvCountForMatrix],JoinOptions[Index] = 1),2)
I can do this with buttons/bookmarks, but I'm curious so...is there another way? Here's a sample .pbix and some screenshots. Thank you! Tom
This one is Great!Want to have it reset to ALL
5 Replies
- amitchandak
Super User
ThomasDay , I doubt on desktop. You have an option in power bi service. So if the report will be viewed on service their option to reset.
- ThomasDay
Impactful Individual
amitchandak Yes, the report will be viewed in power bi service. That's encouraging...how do I reset the slicer in service? Thank you, Tom
- AnonymousNot applicable
Hi ThomasDay,
If you are work on the 'read view' mode of power bi reports, it is possible to use 'rest to default' option to restore all the changes to raw report contents. (it does not clear up all filter effects and it just the restore to raw graph)
Announcing Persistent Filters in the Power BI Service
Regards,Xiaoxin Sheng