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.
Hi,
I have the below visual in my report and my aim is the current year, current month, current week number and current day should be get selected when opening the report.
For doing this, I have done the following methods. But nothings works.
After performing these two steps, still I could see my slicers are asusual and not getting selected to current date as expected.
Please help with clear and proper way. Appreciate your efforts.
Solved! Go to Solution.
@Anonymous , No way to default using a function
We have to you column like this and select Current Month, Today etc
Month Type = Switch( True(),
eomonth(Date[Date],0) = eomonth(Today(),0) ,"Current Month" , //This Month
eomonth(Date[Date],0) < eomonth(Today(),0) && ,"Previous Month" , //last Month
eomonth(Date[Date],0) > eomonth(Today(),0) && ,"Next Month" , //last Month
[Month Year]
)
Week Type = Switch( True(),
Weekday(Date[Date],1) = Weekday(Today(),1) ,"Today" , //This Month
[Week Day]
)
Date Type = SWITCH(TRUE(),'Date'[Date]=TODAY(),"Today"
,'Date'[Date]=TODAY()-1,"Yesterday"
,'Date'[Date]=TODAY()-2,"2 Days Ago"
,'Date'[Date]&"")
@Anonymous , No way to default using a function
We have to you column like this and select Current Month, Today etc
Month Type = Switch( True(),
eomonth(Date[Date],0) = eomonth(Today(),0) ,"Current Month" , //This Month
eomonth(Date[Date],0) < eomonth(Today(),0) && ,"Previous Month" , //last Month
eomonth(Date[Date],0) > eomonth(Today(),0) && ,"Next Month" , //last Month
[Month Year]
)
Week Type = Switch( True(),
Weekday(Date[Date],1) = Weekday(Today(),1) ,"Today" , //This Month
[Week Day]
)
Date Type = SWITCH(TRUE(),'Date'[Date]=TODAY(),"Today"
,'Date'[Date]=TODAY()-1,"Yesterday"
,'Date'[Date]=TODAY()-2,"2 Days Ago"
,'Date'[Date]&"")
@amitchandak The way which you have mentioned, we need to have the values in slicers like Current Year, Current Month, Current Week and Current Day.
But I need something like 2020, September, 38 and Monday. Is this possible ?
@Anonymous ,I doubt that is possible as of now.
Also check -https://www.youtube.com/watch?v=lkHFpmA4SJ4&feature=youtu.be
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 |
---|---|
104 | |
96 | |
79 | |
65 | |
62 |
User | Count |
---|---|
147 | |
116 | |
104 | |
88 | |
65 |