home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / pascal / library / dos / t_power / testcal.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  1988-02-08  |  735 b   |  37 lines

  1. program TestCalendar;
  2.  
  3. uses Dos,
  4.      Crt,
  5.      TpString,              Calendar;
  6.  
  7. const
  8.   TestDates: array[1..7] of string =
  9.     ('12-Feb',
  10.      '2/16/88',
  11.      '12/16/88',
  12.      'Feb-88',
  13.      'Feb 25, 1988',
  14.      '26-Feb-88',
  15.      '13/14/88');
  16.  
  17. var
  18.   D: DateNum;
  19.   T: word;
  20.   I: integer;
  21.  
  22. begin
  23.  
  24.   for I := 1 to 7 do begin
  25.     D := FromLotusDate( TestDates[I] );
  26.     writeln( TestDates[I]:16, ExtDate(D):20, LotusDate(D):12);
  27.     end;
  28.  
  29.   D := FromMMDDYY( '022888' );
  30.   for D := D to D+3 do writeln( ExtDate(D), ' :: ', LotusDate( D ));
  31.   for T := 0 to 1 do writeln( ExtTime( T * 450 ));
  32.   writeln( 'Time Now is: ', ExtTime( TimeNow ));
  33.   writeln( 'Today''s date is: ', ExtDate( Today ));
  34.  
  35.   end.
  36.  
  37.