Forum Discussion

ToniHeinrichsIB's avatar
ToniHeinrichsIB
Frequent Visitor
3 years ago
Solved

Relative time filter with always one option selected

Hi!   I build this time filter with 4 options "last 7 days","last 15 days","last 30 days","since the beginning". It works very well but if none of the options is selected, no data is displayed. Is ...
  • v-yueyunzh-msft's avatar
    v-yueyunzh-msft
    3 years ago

    Hi , ToniHeinrichsIB 

    For the slicer in Power BI , If you don't select a slicer, all filtering contexts are calculated by default. We have no way to modify the slicer, we can only modify our measure, we can use the isfiltered() function to judge the slicer, and when the slicer is not selected, all data is returned.

    For more information, you can refer to :
    ISFILTERED function (DAX) - DAX | Microsoft Learn

     

    Thank you for your time and sharing, and thank you for your support and understanding of PowerBI! 

     

    Best Regards,

    Aniya Zhang

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly