瀏覽代碼

* fixed CompareDate function. Only dates are compared now, ignoring time of day.

git-svn-id: trunk@13949 -
ivost 16 年之前
父節點
當前提交
d4d3227e77
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      rtl/objpas/dateutil.inc

+ 1 - 1
rtl/objpas/dateutil.inc

@@ -1857,7 +1857,7 @@ Function CompareDate(const A, B: TDateTime): TValueRelationship;
 begin
 begin
   If SameDate(A,B) then
   If SameDate(A,B) then
     Result:=EQualsValue
     Result:=EQualsValue
-  else if A<B then
+  else if Trunc(A)<Trunc(B) then
     Result:=LessThanValue
     Result:=LessThanValue
   else
   else
     Result:=GreaterThanValue;
     Result:=GreaterThanValue;