Returns the Number of Weeks between DT2 and DT1.Unit
QESBPCSDateTime
Declaration
Function WeeksApart(const DT1, DT2: TDateTime): LongInt;
Description
If result is 0 then they are in within a Week of each other, if result is negative then DT2 occurs before DT1.
| DT1 | First Date/Time to process. | 
| DT2 | Second Date/Time to process. | 
Category
Date/Time Arithmetic Routines
Week Based Arithmetic Routines
Implementation
 
  | function WeeksApart (const DT1, DT2: TDateTime): Integer;
begin
     Result := DaysApart (DT1, DT2) div 7;
End; | 
| HTML generated by Time2HELP | 
http://www.time2help.com