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 all
I've got this month slicer on a report page that shows the Months from my date table, then i've entered a Page filter so that it only shows the Months in this year, and this slicer expands as we move into new months of the year.
I wish to have the last/newest month selected per default in the Month slicer.
Any ideas on how i can set a default selection on my Month Slicer, that is always the last available month on the slicer?
Solved! Go to Solution.
Hi @MacJasem
You can use the customm visual:preselected slicer, it can set the dafault selection.
You can refer to the following sloution.
1.You need to create a table to set the true or false value.
2.Then you can create a measure to select the max month
Measure = var a=MAXX(ALLSELECTED('Table'),[Month])
return IF(SELECTEDVALUE('Table'[Month])=a,TRUE(),FALSE())
3.Then put the meaure and the true/false table to the slicer field
Output
Best Regards!
Yolo Zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @MacJasem
You can use the customm visual:preselected slicer, it can set the dafault selection.
You can refer to the following sloution.
1.You need to create a table to set the true or false value.
2.Then you can create a measure to select the max month
Measure = var a=MAXX(ALLSELECTED('Table'),[Month])
return IF(SELECTEDVALUE('Table'[Month])=a,TRUE(),FALSE())
3.Then put the meaure and the true/false table to the slicer field
Output
Best Regards!
Yolo Zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @MacJasem
if you don't need the list of months you can use form option of "related date" on slicer :
if you are working with a month list you can use the linked workaround :
https://www.youtube.com/watch?v=5dN4SqufENE
If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly
Hi @Ritaf1983
Thanks for the input👍
But that is not really what i'm looking for.
I already have set up the calculations to handle the dates as in the youtube video you linked to, but the only thing that i'm missing is how to set the default selection of the slicer to dynamically be the last date available in the slicer.
So now the last month of the slicer is October, and i've clicked on October to select the month. I'd like the selection to be done by default and dynamically change to the last month in the slicer. So that next month when we enter November, the slicer will be extended with a new month and that month should now be selected by default.
Any idea on how to do so?
BTW.
- in your screenshot you have the option to chose the slicer to be a relative view, and that's not the case in my desktop🤷♂️
Hi @MacJasem
1. you need to have the "current month" ( not its name ) that is exactly what the video tutorial shows how to modify.
Then you click on it when you publish or select from the list and it will be kept.
The second option - it seems you put the month column and not the date column to the slicer:
you need to put there column with date data type ( not string)
If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly
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 |
---|---|
97 | |
95 | |
76 | |
72 | |
65 |
User | Count |
---|---|
136 | |
109 | |
104 | |
82 | |
73 |