Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreNext up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now
Hello,
Is there a DAX function that will return a logical true/false based on whether or not all slicer options are selected? I.E. if all slicer options are selcted (all selected), result = TRUE. If not all options are selected = FALSE.
Thanks!
Solved! Go to Solution.
Hey @Anonymous ,
yes, the function is called ISCROSSFILTERED.
The following measure will return a TRUE or FALSE if a specific column is filtered or not:
IsFiltered = ISCROSSFILTERED( mySlicerTale[SlicerColumn] )
This you can use then in other measures (IF( ISCROSSFILTERED( ...))
Function? No. But a combination of functions - yes. Assuming the slicer can't have any filtering applied to itself, that is, no measure filters it via the Filter pane and assuming that the slicer holds data from one column only from table T, what you can do is write this measure:
[All Entries Selected] =
var SelectedEntriesCount =
DISTINCTCOUNT( T[SlicerColumn] )
var TotalEntriesCount =
CALCULATE(
DISTINCTCOUNT( T[SlicerColumn] ),
REMOVEFILTERS( T )
)
return
SelectedEntriesCount
= TotalEntriesCount
Of course, if you had a measure filtering the slicer it would also be possible to write such a measure but it would be a bit more complex. It would also require defining what is meant by "all entries selected."
Hey @Anonymous ,
yes, the function is called ISCROSSFILTERED.
The following measure will return a TRUE or FALSE if a specific column is filtered or not:
IsFiltered = ISCROSSFILTERED( mySlicerTale[SlicerColumn] )
This you can use then in other measures (IF( ISCROSSFILTERED( ...))
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 9 | |
| 6 | |
| 3 | |
| 2 | |
| 1 |
| User | Count |
|---|---|
| 21 | |
| 14 | |
| 9 | |
| 5 | |
| 5 |