Topic Path: Symbol Reference > Functions > GmtOffsetStrToDateTime Function
ContentsIndexHome
PreviousUpNext
GmtOffsetStrToDateTime Function

Converts an Internet time difference string to a native date/time value.

File
function GmtOffsetStrToDateTime(
    S: string
): TIdDateTime;
Parameters 
Description 
The Internet time difference string to be converted. 

TDateTime - Native date/time representation of the time difference string.

GmtOffsetStrToDateTime is a TDateTime function used to convert the Internet time difference string in S to a native TDateTime value. 

The return value for GmtOffsetStrToDateTime will contain the time difference from S encoded as a TDateTime value, and can contain either a positive or a negative number of offset hours. 

The return value for GmtOffsetStrToDateTime can be 0.0 if an error occurs during calculation of the offset value. 

GmtOffsetStrToDateTime can be used to create a value that can be added to a TDateTime value expressed in another time zone, to adjust to the local time zone. 

To convert a TDateTime to an Internet Time difference, use the DateTimeToGmtOffSetStr function.

Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Post feedback to the Indy Docs Newsgroup.