You need to sign in to do that
Don't have an account?

How can a date be displayed in the format dd/mm/yyyy in Visualforce?
Hi all,
I am trying to display/retrieve a given date in the format dd/mm/yyyy, but without success til now.
What is being displayed is this:

My code in Visualforce is this:
StartDateTime is a field in the Event object and it is shown that way probably because my time zone is a British timezone:

Users want the timezone in English and not Spanish.
Is there any form to display the date time in the format dd/mm/yyyy? (example: 17/05/2017)
I would appreciate tips.
I am trying to display/retrieve a given date in the format dd/mm/yyyy, but without success til now.
What is being displayed is this:
My code in Visualforce is this:
<td style="white-space:nowrap;"> <apex:inputText value="{0,StartDateTime,MM'/'dd'/'yyyy}" disabled="true" > <apex:param value="{!evento.StartDateTime}" /> <apex:inputText> </td>Even if I replace "inputText" by "outputText", under my problems list appears "disabled not compatible with outputtext.
StartDateTime is a field in the Event object and it is shown that way probably because my time zone is a British timezone:
Users want the timezone in English and not Spanish.
Is there any form to display the date time in the format dd/mm/yyyy? (example: 17/05/2017)
I would appreciate tips.
if all you need is the current date printed out in that format then you can use this:
Hope this helps you!
Best Regards,
Rakesh Thota.
All Answers
if all you need is the current date printed out in that format then you can use this:
Hope this helps you!
Best Regards,
Rakesh Thota.
Use the below code , it gives an inputDateField and displays that in dd/mm/yyyy format
Vf page :
Controller code :
Let me know if you need further help on the code part.
Thanks and Regards,
Shiva RV
I have used both versions of you, but one of them worked best just replacing NOW() by evendate.