cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
beekee
Helper IV
Helper IV

Dynamic chart title to be filtered by Filter pane and slicer

Hi everyone,

 

I have a measure to display dynamic title. This measure is restricted to show the range based on the condition in Filters pane. When I select Fiscal Period = 2021, the measure supposed to show "Total units from Sep'2021 to Dec'2021" but I'm not sure how I can achieve that. Does anyone know how to improve on the measure?

 

Measure = 

VAR startMth = CALCULATE([(Slct) Year_Month_Short],FILTER(Dim_Date,Dim_Date[CurMonthOffset]=0))
VAR endMth = CALCULATE([(Slct) Year_Month_Short],FILTER(Dim_Date,Dim_Date[CurMonthOffset]=8))
return
"Total units from " & startMth & " to " & endMth
 

 

When Fiscal Period = All

beekee_0-1630902068475.png

 

When Fiscal Year = 2021

beekee_1-1630902104988.png

 

 

Regards,

BK

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@beekee , if your fiscal year start from Sep and end at Aug.

 

You can use datesytd with date table 

examples

 

YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD('Date'[Date],"8/31"))
Last YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(dateadd('Date'[Date],-1,Year),"8/31"))

 

refer if needed

Creating Financial Calendar - From Any Month
https://community.powerbi.com/t5/Community-Blog/Creating-Financial-Calendar-Decoding-Date-and-Calend...

 

Power BI — Year on Year with or Without Time Intelligence
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
https://www.youtube.com/watch?v=km41KfM_0uA

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! !!
Dashboard of My Blogs !! Connect on Linkedin
Want To Learn Power BI
Learn Power BI Beginners !! Advance Power BI Concepts !! Power BI For Tableau User !! Learn Power BI in Hindi !!
Proud to be a Super User!
!! Subscribe to my youtube Channel !!

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@beekee , if your fiscal year start from Sep and end at Aug.

 

You can use datesytd with date table 

examples

 

YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD('Date'[Date],"8/31"))
Last YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(dateadd('Date'[Date],-1,Year),"8/31"))

 

refer if needed

Creating Financial Calendar - From Any Month
https://community.powerbi.com/t5/Community-Blog/Creating-Financial-Calendar-Decoding-Date-and-Calend...

 

Power BI — Year on Year with or Without Time Intelligence
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
https://www.youtube.com/watch?v=km41KfM_0uA

Did I answer your question? Mark my post as a solution! Appreciate your Kudos!! !!
Dashboard of My Blogs !! Connect on Linkedin
Want To Learn Power BI
Learn Power BI Beginners !! Advance Power BI Concepts !! Power BI For Tableau User !! Learn Power BI in Hindi !!
Proud to be a Super User!
!! Subscribe to my youtube Channel !!

Helpful resources

Announcements
May 23 2022 epsiode 5 without aka link.jpg

The Power BI Community Show

Welcome to the Power BI Community Show! Jeroen ter Heerdt talks about the importance of Data Modeling.

charticulator_carousel_with_text (1).png

Charticulator Design Challenge

Put your data visualization and design skills to the test! This exciting challenge is happening now through June10th!

Power BI Dev Camp Session 22 without aka link and time 768x460.jpg

Check it Out!

Watch Session 22 Ted's Dev Camp along with past sessions!

Power BI Release May 2022 768x460.png

Check it out!

Click here to read more about the May 2022 updates!

Top Kudoed Authors