|
@@ -111,6 +111,7 @@ Function Yesterday: TDateTime;
|
|
|
Function Tomorrow: TDateTime;
|
|
|
Function IsToday(const AValue: TDateTime): Boolean;
|
|
|
Function IsSameDay(const AValue, ABasis: TDateTime): Boolean;
|
|
|
+function IsSameMonth(const Avalue, ABasis: TDateTime): Boolean;
|
|
|
Function PreviousDayOfWeek (DayOfWeek : Word) : Word;
|
|
|
|
|
|
{ ---------------------------------------------------------------------
|
|
@@ -618,6 +619,12 @@ begin
|
|
|
Result:=(D>=0) and (D<1);
|
|
|
end;
|
|
|
|
|
|
+function IsSameMonth(const Avalue, ABasis: TDateTime): Boolean;
|
|
|
+begin
|
|
|
+ result:=( YearOf(Avalue) = YearOf(Abasis) );
|
|
|
+ result:=result and ( MonthOf(AValue) = MonthOf(ABasis) );
|
|
|
+end;
|
|
|
+
|
|
|
const
|
|
|
DOWMap: array [1..7] of Word = (7, 1, 2, 3, 4, 5, 6);
|
|
|
|