Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

CheckDay(Integer,Integer,Integer) Method

Returns the valid day for a specific date.

#Declaration

Delphi
function CheckDay(AYear: Integer; AMonth: Integer; ADay: Integer): Integer;

#Parameters

Name Type
AYear Integer
AMonth Integer
ADay Integer

#Returns

Type
Integer

#Remarks

The CheckDay function returns the valid day for the date defined by the AYear, AMonth and ADay parameters. If the ADay parameter is less than 1, the function returns the first day of the month, i.e. 1. If it is greater than the total number of days in a given month and year, CheckDay returns the last day of the month. Otherwise, the ADay parameter is a valid day returned by the function.

See Also