DateUtils.IsValidDate
From RAD Studio VCL Reference
Contents |
Delphi Information
From DateUtils.pas
function IsValidDate(const AYear: Word; const AMonth: Word; const ADay: Word): Boolean;
Unit: DateUtils
Type: function
Visibility: public
C++ Information
From DateUtils.hpp
bool __fastcall IsValidDate(unsigned short AYear, unsigned short AMonth, unsigned short ADay);
Unit: DateUtils
Type: function
Description
Indicates whether a specified year, month, and day represent a valid date.
IsValidDate returns True if:
- AYear falls in the range from 1 through 9999 inclusive.
- AMonth falls in the range from 1 through 12 inclusive.
- ADay falls in the range from 1 through the number of days in the specified month.
Otherwise, IsValidDate returns False.
See Also
Code Samples