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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
New_Folder
Helper I
Helper I

Show blank " " on CARDS when nothing is selected on a Graph with Drill down.

I have a table of dates and number of instances per date. I set up a drill down. I would like to show the Year when drilling down. Currently the option that I can see is Min - Max. I am not familiar with DAX, but can follow instructions.

The first table shows the Years and the second is the drilled down. As you can see, it does not show which Year was selected. I would like the Year to show either on the Title or on a separate Card visual.

New_Folder_0-1661351026333.png

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@New_Folder , You can create a measure

 

if(isfiltered(Date[Year]), selectedvalue(Date[Year]), "All Year")

 

You can use this measure in title or card

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

3 REPLIES 3
PaulDBrown
Community Champion
Community Champion

First, go into the x-axis in the formatting pane and make sure the Type is set to coninuous.

Expand the visual as

2022-08-24.png

go into the x-axis in the formatting pane and turn off concatenate labels.

concat labels.png

 

 

 

Optionally, you can add a dynamic title to the visual to help guide your users. Create a measure along the lines of:

Year Title =
VAR _MinYear =
    CALCULATE ( MIN ( 'Calendar Table'[Year] ), ALL ( 'Calendar Table'[Year] ) )
VAR _MaxYear =
    CALCULATE ( MAX ( 'Calendar Table'[Year] ), ALL ( 'Calendar Table'[Year] ) )
VAR _Sel =
    CONCATENATEX ( VALUES ( 'Calendar Table'[Year] ), 'Calendar Table'[Year], ", " )
RETURN
    IF (
        ISFILTERED ( 'Calendar Table'[Year] ),
        "Sales for " & _Sel,
        "Sales from " & _MinYear & " to " & _MaxYear
    )

In the formatting pane, go into General -> Title and add the measure to the conditional formatting option, 2022-08-24 (1).png

 

Captura de pantalla 2022-08-24 174744.png

 Now you are ready to go. Just beware that the "Drilling" / Hierarchy ribbon can be confusing to users. (Here the title really helps)

1) "Go to next level of the hierarchy" displays aggregated data by month for all the years 

Hierarchy.gif

 

2) "Expand all down one level in the hiearchy" still displays data for all the years, but by month and year:

Expand.gif

 3) By turning on the "drill-down" option, you can access a particular year data by clicking on a data point

Drill.gif

 

Hope this helps

 

 

 

 





Did I answer your question? Mark my post as a solution!
In doing so, you are also helping me. Thank you!

Proud to be a Super User!
Paul on Linkedin.






amitchandak
Super User
Super User

@New_Folder , You can create a measure

 

if(isfiltered(Date[Year]), selectedvalue(Date[Year]), "All Year")

 

You can use this measure in title or card

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

I might miss a detail here, should I replace something on the formula you provided? Im getting this error,

 

New_Folder_0-1661360059184.png

I think I got it working. How do I format to remove the thousands comma separator?

New_Folder_1-1661360423376.png

ugh, nevermind, found it.. thank you very much awesome internet people.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.