cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
dw700d
Helper V
Helper V

Default Value 0

I have card visuals that show the total amount of toys, cars, cats and houses. I am slicing this data by date. if a date is not selected in the slicer I would like the default value of the card visual to be 0. If a date is selected then the appropriate filtering should flow through. Is there a measure that can help me accomplish this?

 

dw700d_0-1676000588835.png

 

2 ACCEPTED SOLUTIONS
Ahmedx
Solution Sage
Solution Sage
v-zhangti
Community Support
Community Support

Hi, @dw700d 

 

You can try the following methods.
Sample data:

vzhangti_0-1676268475051.png

SUM = SUM('Table'[Value])
Measure = IF(ISFILTERED('Table'[Date]),[SUM],0)

vzhangti_1-1676268516536.pngvzhangti_2-1676268524176.pngvzhangti_3-1676268534832.png

Is this the result you expect?

 

Best Regards,

Community Support Team _Charlotte

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-zhangti
Community Support
Community Support

Hi, @dw700d 

 

You can try the following methods.
Sample data:

vzhangti_0-1676268475051.png

SUM = SUM('Table'[Value])
Measure = IF(ISFILTERED('Table'[Date]),[SUM],0)

vzhangti_1-1676268516536.pngvzhangti_2-1676268524176.pngvzhangti_3-1676268534832.png

Is this the result you expect?

 

Best Regards,

Community Support Team _Charlotte

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

Ahmedx
Solution Sage
Solution Sage

Helpful resources

Announcements
May 2023 update

Power BI May 2023 Update

Find out more about the May 2023 update.

Submit your Data Story

Data Stories Gallery

Share your Data Story with the Community in the Data Stories Gallery.

Top Solution Authors