function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

How to get respective user's locale on VF page?

Hi All,


I want to display a date field value in Visualforce page.


Accoring to user "locale" selection... the date format should get change.


if the user is from US then date should display as "MM/DD/YYYY" format and For UK user date should display as "DD/MM/YYYY" format.


Any possible solution?


Many thanks,


use the code below.


<apex:column >
            <apex:facet name="header">Close Date</apex:facet>
            <apex:outputText value=" {!dto.o.CloseDate}">                


a matter of space on the value.