Internet Direct (Indy)
Home
PreviousUpNext
GmtOffsetStrToDateTime Function

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

Pascal
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.

Internet Direct (Indy) version 10.1.5
Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Website http://www.indyproject.org.
Post feedback to the Indy Documentation newsgroup.