[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'sysutils' (#rtl)

SystemTimeToDateTime

Convert a system time to a TDateTime value.

Declaration

Source position: datih.inc line 124

function SystemTimeToDateTime(

  const SystemTime: TSystemTime

):TDateTime;

Description

SystemTimeToDateTime converts a TSystemTime record to a TDateTime style date/time indication.

Errors

None.

See also

DateTimeToSystemTime

  

Converts a TDateTime value to a systemtime structure.

Example

Program Example22;

{ This program demonstrates the SystemTimeToDateTime function }

Uses sysutils;

Var ST : TSystemTime;

Begin
  DateTimeToSystemTime(Now,ST);
  With St do
    begin
    Writeln ('Today is    ',year,'/',month,'/',Day);
    Writeln ('The time is ',Hour,':',minute,':',Second,'.',MilliSecond);
    end;
  Writeln ('Converted : ',DateTimeToStr(SystemTimeToDateTime(ST)));
End.

Documentation generated on: Nov 16 2015