DateUtils.DaysBetween
From RAD Studio VCL Reference
Contents |
Delphi Information
From DateUtils.pas
function DaysBetween(const ANow: TDateTime; const AThen: TDateTime): Integer;
Unit: DateUtils
Type: function
Visibility: public
C++ Information
From DateUtils.hpp
int __fastcall DaysBetween(System::TDateTime ANow, System::TDateTime AThen);
Unit: DateUtils
Type: function
Description
Returns the number of whole days between two specified TDateTime values.
Call DaysBetween to obtain the difference, in days, between two TDateTime values.
DaysBetween counts only whole days. Thus, DaysBetween reports the difference between Dec 31, 1999 11:59 P.M. and Jan 1, 2000 11:58 P.M. as 0, because the difference is one minute short of an entire day.
See Also
Code Samples