DatesInSameYear Function
Returns true if both DateTimes refer to the same Year.

Unit
QESBPCSDateTime

Declaration
Function DatesInSameYear(const DT1, DT2: TDateTime): Boolean;

Parameters
DT1 First Date/Time to process.
DT2 Second Date/Time to process.

Category
Date/Time Arithmetic Routines
Year Based Arithmetic Routines
Date/Time Comparison

Implementation

function DatesInSameYear (const DT1, DT2: TDateTime): Boolean;
begin
     Result := Date2Year (DT1) = Date2Year (DT2);
End;


HTML generated by Time2HELP
http://www.time2help.com