summaryrefslogtreecommitdiff
path: root/fpcdocs/datutex/ex21.pp
blob: ebe952ef5f76c902b030f9139e38d0775e7bd300 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Program Example21;

{ This program demonstrates the IsSameDay function }

Uses SysUtils,DateUtils;

Var
  I : Integer;
  D : TDateTime;

Begin
  For I:=1 to 3 do
    begin
    D:=Today+Random(3)-1;
    Write(FormatDateTime('dd mmmm yyyy "is today : "',D));
    Writeln(IsSameDay(D,Today));
    end;
End.