Supplies are limited. Contact info@espc.tech right away to save your spot before the conference sells out.
Get your discountScore big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount
I'm trying to show in a card what values are selected from a filter. The card should display the words selected.
In case all are selected it should display "ALL" and in case none is selected display "NONE". I have found the following solution which works https://community.powerbi.com/t5/Desktop/Text-field-to-show-the-selected-filter/m-p/251023/highlight...
However, when none is selected it still displays "ALL".How can I make it display "NONE"?
Solved! Go to Solution.
Try this
Measure =
VAR _count =
CALCULATE (
DISTINCTCOUNTNOBLANK ( 'Table'[Column1] ),
ALL ( 'Table'[Column1] )
)
VAR _countinscope =
DISTINCTCOUNTNOBLANK ( 'Table'[Column1] )
VAR _result =
IF (
ISFILTERED ( 'Table'[Column1] ),
IF (
_count = _countinscope,
"All",
CONCATENATEX (
'Table',
[Column1],
","
)
),
"None"
)
RETURN
_result
Did I answer your question? Mark my post as a solution!
Appreciate with a kudos 🙂
Try this
Measure =
VAR _count =
CALCULATE (
DISTINCTCOUNTNOBLANK ( 'Table'[Column1] ),
ALL ( 'Table'[Column1] )
)
VAR _countinscope =
DISTINCTCOUNTNOBLANK ( 'Table'[Column1] )
VAR _result =
IF (
ISFILTERED ( 'Table'[Column1] ),
IF (
_count = _countinscope,
"All",
CONCATENATEX (
'Table',
[Column1],
","
)
),
"None"
)
RETURN
_result
Did I answer your question? Mark my post as a solution!
Appreciate with a kudos 🙂
Thank you @nandukrishnavs it works perfectly but what if the "select all" option is on?
Hi @psilos24 ,
I think "select all" might not work, based on my test, I find that the IsFiltered can't distinguish the difference between allselect and unselect". So I suggest you need to disbale this option.
Best Regards,
Zoe Zhi
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@psilos24 Try that, it should work.
Did I answer your question? Mark my post as a solution!
Appreciate with a kudos 🙂
@psilos24 , you can use is filtered or hasonevalue
https://powerpivotpro.com/2013/03/hasonevalue-vs-isfiltered-vs-hasonefilter/
if(isfiltered(Table[A]),Table[A],"None")