ScriptCore3.DecodeDate

From Soldat Community Wiki
Revision as of 09:42, 25 August 2013 by Mighty (talk | contribs) (new page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
procedure DecodeDate(const DateTime: TDateTime; var Year, Month, Day: Word);
 DateTime: TDateTime that is supposed to be decoded
 Year: Year based on DateTime
 Month: Month based on DateTime
 Day: Day based on DateTime

Description

This function will decode given TDateTime into Year, Month and Day.

Example

var
  y,m,d: Word;

begin
  DecodeDate(71001,y,m,d);
  {
  y = 2094
  m = 5
  d = 22
  }
  WriteLn(inttostr(y));
  WriteLn(inttostr(m));
  WriteLn(inttostr(d));
end.