This is best Fabric, Power BI, SQL and AI community event. How do we know? The last event sold out! Save €200 with code FABCMTY200.
Register nowA new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.
Dear All,
I have a slicer window with a date field as below. On page load, I want this field to auto select the current date. Can somebody please help on this urgently.
For e.g today it should auto select 02/09/2018, tomorrow it should be 03/09/2018 and son on.
Regarsds,
Shahin K
Solved! Go to Solution.
Hi @Shahinkmajeed,
You can't do this directly in the report designer, but you should be able to do some modelling to make it work. Here I made one sample for your reference.
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjIwtNA3sNQ3MFTSUTJUitVBEjICChmhCoFUGaMKGQOFTJRiYwE=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [date = _t, sale = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"date", type date}, {"sale", Int64.Type}}),
#"Added Custom" = Table.AddColumn(#"Changed Type", "Custom", each if Date.IsInCurrentDay( [date] )
then "Today"
else [date])
in
#"Added Custom"Also you can use DAX to get the similar result.
Column2 = IF(Table1[date]=TODAY(),"today",CONCATENATE(Table1[date],""))
Here is the result for your reference.
For more details, please check the pbix as attached.
https://www.dropbox.com/s/qbjxrul1ytjjq7d/slicer.pbix?dl=0
Regards,
Frank
Hi @Shahinkmajeed,
You can't do this directly in the report designer, but you should be able to do some modelling to make it work. Here I made one sample for your reference.
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMjIwtNA3sNQ3MFTSUTJUitVBEjICChmhCoFUGaMKGQOFTJRiYwE=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [date = _t, sale = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"date", type date}, {"sale", Int64.Type}}),
#"Added Custom" = Table.AddColumn(#"Changed Type", "Custom", each if Date.IsInCurrentDay( [date] )
then "Today"
else [date])
in
#"Added Custom"Also you can use DAX to get the similar result.
Column2 = IF(Table1[date]=TODAY(),"today",CONCATENATE(Table1[date],""))
Here is the result for your reference.
For more details, please check the pbix as attached.
https://www.dropbox.com/s/qbjxrul1ytjjq7d/slicer.pbix?dl=0
Regards,
Frank
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 27 | |
| 26 | |
| 22 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 45 | |
| 44 | |
| 41 | |
| 21 | |
| 18 |