Forum Discussion

TSzreder's avatar
TSzreder
Frequent Visitor
5 years ago
Solved

Dynamic date formatting based on user's browser language

Hi all, I am supporting one of the clients that wants the date in his report to change formatting based on the user's browser language. Theoretically this should be possible by using one of the dat...
  • v-yalanwu-msft's avatar
    5 years ago

    Hi TSzreder , 

    Because your yellow mark is the general date format, and red is the custom date, so when you change the language, only the language difference will be displayed, and the format is custom/fixed. If you want to achieve dynamic language, you can try to use slicer or set in power query

    Slicer way1:

    1.Enter table as language slicer

    2.Create a measure

    Measure =
    SWITCH (
        MAX ( 'Slicer'[language] ),
        "Polish", FORMAT ( MAX ( [Date] ), "dd/mm/yyyy" ),
        "US", FORMAT ( MAX ( [Date] ), "mm/d/yyyy" )
    )
    

    The final output is shown below:

    Power query way2:

    Best Regards,
    Community Support Team_ Yalan Wu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.