I used the following AMPSCRIPT to get the date and time displayed on the email at the time of send:

Code block:

<!-- date/time -->
VAR @today 
SET @today = SystemDateToLocalDate(Now(1))

Inline code : %%=FormatDate(@today,"d MMMM yyyy à ", "HH'h'mm","fr-FR")=%%

The date and time are displayed correctly on the email once it is received. However, when clicking on View Online, it is another date and time (an older one, like 2 days before...).

Is that normal ? Is there anything we can do to display the same date/time on the View Online page ?

Thank you




There are three options for this to retain time displayed in email:

  1. Now(1): Originally it provides current time. After send it provides job start time/Job publish time for Triggers/Journeys. This can be an issue for Triggers as there are times that it could be days, weeks or even months since the email was last published (which is likely the issue you are facing).
  2. GetSendTime(): This one is pretty much 100% identical to Now(1) in every way.
  3. GetSendTime(1): This is the recommended one I would use as it utilizes 'Subscriber send completed time' instead of based off job start/publish times.

Long story short, I would recommend utilizing GetSendTime(1) instead of Now(1) in your above code.

enter image description here

  • Thank you @Gortonington
    – Ludivine L
    Jan 29 '20 at 9:47
  • However, it seems that it is still not working correctly for the client...! these are Triggered Sends emails. The client made new tests. The day on the email and the online version were the same, but not the time. On the email, it was 21:41 and 14:44 on the online version (when the Triggered send was published and activated...). Is there another solution for that ? Thank you
    – Ludivine L
    Jan 30 '20 at 9:25
  • Using GetSendTime is the only solution for this. Any time discrepancy should be minimal. If there is a significant difference, I would put in a support ticket to find out why. Other solution is to store the time in a DE and do a lookup during VAWP but this is not scalable and greatly increases processing used. Jan 30 '20 at 14:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.