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,
We have a report with a few slicers (3) that can be changed.
One of the slicers is a date slicer to choose between the months. Now when you save and publish it to the service, by opening you always see the options when you saved it.
Can we change it that users always see the last month for example? So it change throught the year?
kind regards,
Davina
Solved! Go to Solution.
Hello @Anonymous
You can do something like this
Default Month Slicer =
IF (
MONTH ( NOW () ) = MONTH ( Dates[Date] )
&& YEAR ( NOW () ) = YEAR ( Dates[Date] ),
"Current Month",
Dates[Year-Month]
)
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly and I would love to see your like Or
If you could send sample .pbix that demonstrate what you are looking to get. It would really help providing you a quick implemented solution.
Regards
Kumail Raza
@KumailThanks, it works today.
Now i see the current month for june, but is it also possible to see both "current month" and "june"?
@Anonymous
Please consider Accept it as the solution to help the other members find it more quickly and consider like if it helped you!!
Regards
Kumail Raza
@Kumailit works but I had another question in my previous reply.
If you can answer this one, I can accept this.
Question: Now i see the current month for june, but is it also possible to see both "current month" and "june"?
@Anonymous
If you could send sample .pbix that demonstrate what you are looking to get. It would really help providing you a quick solution.
Regards
Kumail Raza
@Anonymous
Default Current/Recent Month Slicer =
IF (
MONTH ( NOW () ) = MONTH ( 'Table'[Date] )
&& YEAR ( NOW () ) = YEAR ( 'Table'[Date] ),
"Current Month "& FORMAT(NOW(),"mmmm-yyyy"),
FORMAT(MAX( 'Table'[Date] ),"mmmm-yyyy")
)
This will add "Current Month" along side name of the month if the condition fulfils for current month.
If you could send sample .pbix that demonstrate what you are looking to get. It would really help providing you a quick solution.
Hope the above solution helps.
Regards
Kumail Raza
@StefanoGrimaldi& @Kumail Thanks for your feedback, but this is a filter. I'm using slicers, so if I add this to the slicer or at any other visual it will always show last month. Meaning of our reports is opening in default value of last month, but also the possibility to change to an other month.
@Anonymous
Yes, this will give you current month and you can keep it as default slicer when publishing. The user will also have option to change slicer to other months if that is allowed in the published report.
If you could send sample .pbix that demonstrate what you are looking to get. It would really help providing you a quick solution.
Hope this helps.
Regards
Kumail Raza
Hello @Anonymous
You can do something like this
Default Month Slicer =
IF (
MONTH ( NOW () ) = MONTH ( Dates[Date] )
&& YEAR ( NOW () ) = YEAR ( Dates[Date] ),
"Current Month",
Dates[Year-Month]
)
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly and I would love to see your like Or
If you could send sample .pbix that demonstrate what you are looking to get. It would really help providing you a quick implemented solution.
Regards
Kumail Raza
hey,
theres a option when you put a field on the filter pane (if its a date field) thats called relative filter (appears in a dropdown on the field filter on the filter pane), there you do have the option to filter by month you select the one called last X month and specify 1 month.
now for making it work for the last month them you will need to make a little dax that get the current month first day -1 and use that field for the relative filter if.
Proud to be a Super User!
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 |
---|---|
115 | |
99 | |
86 | |
70 | |
62 |
User | Count |
---|---|
151 | |
120 | |
103 | |
87 | |
68 |