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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
lg1551
Resolver II
Resolver II

KPI Card - Need Conditional Target Trend Line

I am using the 'Card With States' by OKVIZ visual from the Market Place.

 

I currently have a trendline on the bottom of the card (it's one of the visual's options) and I use the month column from my date table there.

 

I am now needing to add a slicer to the report page but some of the slicer values do not apply to the card. 

 

I've written my measures for the metric and target to BLANK() the values if the non-applicable slicer values are selected but the problem is that the trend line still shows. 

 

I need a measure that will calculate the month (from the month column) but that I can add the same IF(SelectedValue([Slicer] = "", then BLANK() logic to. 

I've tried the intuitive method of IF(SelectedValue([Slicer] = "", then BLANK(), 'Date' [Month]. But it wants a measure, not the column. 

Any ideas?

 

 

2 REPLIES 2
v-easonf-msft
Community Support
Community Support

Hi, @lg1551 

You can try using function 'ISFILTERED'.

Measure =IF ( ISFILTERED ( 'Table'[Slicer] ), [your measure], BLANK () )

 

Best Regards,
Community Support Team _ Eason

That doesn't work unfortunately. 

I have the conditional issue for the slicers where if certain slicer elements are selected, I want the entire card to go blank. But what happens, is the primary and target measures go blank, but the trend line becomes a solid line across the bottom instead of disappearing as well. So I'm thinking I need to have a measure that will display the month trend line only if the applicable slicers are selected. But I'm having trouble with the logic. The trend line right now is just the month column from the date table. I need to convert this to a dynamic measure. Any thoughts?

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.