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
Mark LeadbetterMark Leadbetter 

Formatting Dates in Visual force email template

Hi,
I am creating a visual force email template and I need to format the dates. At the moment my code looks like:
<p>Date Actual Invoice Required:{!relatedto.Date_Actual_Invoice_Required__c}</P>
<p>Date proforma invoice required: {!relatedto.Date_Actual_Invoice_Required__c} (</P>

The date is in the format Wed Aug 20 00:00:00 GMT 2014.
I would like to Day Month Year format please, can you tell me how to do this?
thanks in advance

 
Raghu Reddy 14Raghu Reddy 14

Hi Mike,

You can do something like this.

Date Actual Invoice Required:
 <apex:outputText value="{0, date, MMMM d','  yyyy}">
    <apex:param value="{!relatedto.Date_Actual_Invoice_Required__c}" />
</apex:outputText>

Date proforma invoice required:
<apex:outputText value="{0, date, MMMM d','  yyyy}">
    <apex:param value="{!relatedto.Date_Actual_Invoice_Required__c}" />
</apex:outputText>


/Raghu