Forum Discussion

Elisa_E's avatar
Elisa_E
Helper I
9 years ago
Solved

Dynamic text based on slicer

Hi,

I have a dataset with three key columns (country, category, and value). Some countries do not have data in the value column for some categories.

 

I have certain visuals connected to a country slicer that I would like to display only if there is data, and to have text show up "No data available" when the country selected is empty. Is there a way to do this?

 

 

Thanks!

  • Elisa_E,

     

    You may add a measure for Card visual.

    Measure =
    IF (
        ISFILTERED ( Table1[country] ),
        SUM ( Table1[value] ),
        "No data available"
    )
    

1 Reply

  • v-chuncz-msft's avatar
    v-chuncz-msft
    Community Support

    Elisa_E,

     

    You may add a measure for Card visual.

    Measure =
    IF (
        ISFILTERED ( Table1[country] ),
        SUM ( Table1[value] ),
        "No data available"
    )