cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
jorgegarioli Frequent Visitor
Frequent Visitor

Slicers, if statement, aglomerate

Hello everyone,

I want to know if there is a way to create (maybe using DAX) an IF statement that when I select all options within my slicer, a new label appears as LEGEND of my graphs.

For example, I have a hierarchy slicer like this:

-Europe

       - France

       - Portugal

       - Italy

          ...

If I select all the countries I want the label in my graphics to be Europe and not each separated country.

Thank you

1 REPLY 1
Community Support Team
Community Support Team

Re: Slicers, if statement, aglomerate

@jorgegarioli,

 

You may try the following condition.

CALCULATE (
    DISTINCTCOUNT ( Table1[country] ),
    Table1[region] = "Europe",
    ALL ( Table1[country] )
)
    = CALCULATE (
        DISTINCTCOUNT ( Table1[country] ),
        Table1[region] = "Europe",
        ALLSELECTED ( Table1[country] )
    )
Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

Community News & Announcements

Community News & Announcements

Get your latest community news and announcements.

Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Community Kudopalooza

Win Power BI Swag with Community Kudopalooza!

Each week, complete activities and be qualified in the drawing for cool Power BI Swag.

Users Online
Currently online: 6 members 3,940 guests
Please welcome our newest community members: