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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Anonymous
Not applicable

Hide card in conditional situation

Hi I am creating a dashboard and I have a calendar view and three cards (A. total stops; B: Total Routes; C: Stops per route, which is dividing total stops by total routes)

 

I am feeding the calendar visual with data of total stops. So when I click on each date, it cross filters the card and shows stops, routes, and stops per route for that speciic date.

 

Everything is fine for now. When I unclick the date, which shows the overview of that month (let's say October), cards for total stops and total routs are correct since it shows the total of that month. However, stops per route will not since it sums up all stops per route that month. But I want to show (total stops of that month)/ (total routes that month)

 

Is there a way I can do that? By using bookmark or using measure....?

I also have a card showing the date that I selected and I want it to show October when I unclick the dates in calendar.

 

Thank you!

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

 

You could simply use IF() and ISFILTER() function to create measure to display different values in different situations.

For example:

measure = IF(ISFILTERED('calendar'[date]),selectedvalue('calendar'[date]),max('calendar'[date].month))

 

Best Regards,

Jay

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hi @Anonymous ,

 

You could simply use IF() and ISFILTER() function to create measure to display different values in different situations.

For example:

measure = IF(ISFILTERED('calendar'[date]),selectedvalue('calendar'[date]),max('calendar'[date].month))

 

Best Regards,

Jay

Kumail
Post Prodigy
Post Prodigy

Hello @Anonymous 

 

If you could send sample .pbix that demonstrate what you are looking to get. It would really help providing you a quick solution.
 
You can send the sample .pbix file by adding it to your drive or dropbox and add the link here. 
 
Regards
Kumail Raza

amitchandak
Super User
Super User

@Anonymous , use isfiltered and check is month or date filtered and based on that change measure

https://powerpivotpro.com/2013/03/hasonevalue-vs-isfiltered-vs-hasonefilter/

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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