LocalDateToSystemDate

Converts a local datetime string to the system time.

The system time is North American Central Standard Time (UTC-6) without adjustments for daylight saving time. The local time is the time of your Marketing Cloud Engagement user account, which can be configured in Setup.

Availability 

Marketing Cloud Engagement ✅ Yes
Marketing Cloud Next ❌ No

Syntax 

1LocalDateToSystemDate(timeToConvert)

The LocalDateToSystemDate() function has one parameter:

  • timeToConvert (string): Required. The time string that you want to convert.

Usage 

This example returns the local time based on the value contained in the @currentSystemTime variable, then converts it back to system time.

1%%[
2  Var @currentSystemTime
3  Set @currentSystemTime = Now()
4]%%
5
6<p>Local Time For User:  %%=SystemDateToLocalDate(@currentSystemTime)=%%</p>
7<p>Converted Back to System Time %%=LocalDateToSystemDate(@currentSystemTime)=%%</p>

See Also