Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Amir851
Helper I
Helper I

Dynamic Text as Title

HI All,

 

I have three slicer in my report and I have made them independent of each other so It wont filter out the other slicer based on the value from first Filters.

 

How Can I create a Dynamic Title that wil display the title only if all the three filters has been selected and also those filters should has value in the table(since they are made independent of each other, so there will be possibilties that few values in filter 3 may not be present for a value selected in filter 1.  In this case my report will be blank and in this moment I want to display title as " please select the value "

 

below is my DAX I Created

 

Title = IF(
AND(ISFILTERED(Table(slicer1)),ISFILTERED(Table(slicer2)),
"Value of " & SELECTEDVALUE(Table(slicer1)) & " for the Year " & SELECTEDVALUE(Table(Slicer2))," Please Select Required Values From All the Filters")
1 ACCEPTED SOLUTION
v-cherch-msft
Employee
Employee

Hi @Amir851

 

You may add a condition with HASONEVALUE Function.Attached the sample file for reference.

Measure = 
IF (
    ISFILTERED ( 'Table'[Slicer1] ) && ISFILTERED ( 'Table'[Slicer2] )
        && HASONEVALUE ( 'Table'[value] ),
    "Value of " & SELECTEDVALUE ( 'Table'[Slicer1] )
        & " for the Year "
        & SELECTEDVALUE ( 'Table'[Slicer2] ),
    " Please Select Required Values From All the Filters"
)

Regards,

Cherie

Community Support Team _ Cherie Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-cherch-msft
Employee
Employee

Hi @Amir851

 

You may add a condition with HASONEVALUE Function.Attached the sample file for reference.

Measure = 
IF (
    ISFILTERED ( 'Table'[Slicer1] ) && ISFILTERED ( 'Table'[Slicer2] )
        && HASONEVALUE ( 'Table'[value] ),
    "Value of " & SELECTEDVALUE ( 'Table'[Slicer1] )
        & " for the Year "
        & SELECTEDVALUE ( 'Table'[Slicer2] ),
    " Please Select Required Values From All the Filters"
)

Regards,

Cherie

Community Support Team _ Cherie Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Greg_Deckler
Super User
Super User

You could use ISFILTERED I believe or logic to see if the slicer is in the context of ALL. See my quick measure for ideas:

 

https://community.powerbi.com/t5/Quick-Measures-Gallery/The-Most-Amazing-Mind-Blowing-Dynamic-Slicer...

 


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.