localToUTCTime

localToUTCTime(): TimeStamp;

The localToUTCTime method of the TimeStamp primitive type converts a timestamp in local time to Coordinated Universal Time (UTC) using the time zone of the machine in which the method executes; for example, if the method is executing in an application server for a presentation client running on another machine, the bias is taken from the time zone of the machine running the application server.

To convert between local and UTC time in a thin client application in which you want to be sensitive to the bias of the presentation client machine, use the localToUTCTimeUsingBias method, as shown in the following code fragment.

self.localToUTCTimeUsingBias(app.currentUTCBias(PresentationClient));

Translations between UTC and local time are based on the formula UTC = local time + bias.

Greenwich Mean Time (GMT) has been replaced as the world standard time by Coordinated Universal Time (UTC), which is based on atomic measurements rather than the rotation of the earth. (GMT remains the standard time zone for the Prime Meridian, or zero longitude.)

See also the TimeStamp primitive type localToUTCTimeUsingBias, utcToLocalTime, and utcToLocalTimeUsingBias methods and the Application class currentUTCBias and getUTCTime methods.