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.
I have a slicer option that is "6/1/2020". When de-selected I need it to turn both measures blank.
JunProj = CALCULATE(SUM(Projections[Amount]), Projections[Month] = "6/1/2020")
I have another measure that also needs to be controlled by this filter. It combines JunProj and any actual sales before that date. It's a mess but I've been having trouble figuring this out:
Jun 20 = TOTALYTD([JunProj], 'Date'[Date])
+
IF(AND(
calculate(sum(
Opportunity[Amount]),Opportunity[StageName]="Closed Won",Opportunity[CloseDate]<date(2020,6,1))
= TOTALYTD([JunProj], 'Date'[Date]),
CALCULATE([JunProj]>date(2020,6,1))=BLANK()),
BLANK(),
TOTALYTD(CALCULATE(SUM(Opportunity[Amount]),Opportunity[StageName] = "Closed Won",Opportunity[CloseDate] < DATE(2020,6,1)) , 'Date'[Date])
)
It still displays data prior to 2020,6,1:
Solved! Go to Solution.
I was able to solve the problem with the following formula:
@morgtd30 , use is filtered
if(ISFILTERED('Jun'[slicer]),[junproj],blank())
Also to be clear it's June 20 that is still displaying data:
I was able to solve the problem with the following formula:
Copying DAX from this post? Click here for a hack to quickly replace it with your own table names
Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C
I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com
Here's what the line graph looks like. I'm building a way to compare YTD projections for any given current or historical month. The 6/1/2020 is one of many filters to remove the lines off the graph as necessary. The green line is the current YTD. It works great other than those amounts that still show up even after the month is filtered out. It causes the tool-tip to fill with bad data.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
58 |
User | Count |
---|---|
148 | |
111 | |
93 | |
84 | |
66 |