Method Get():badDate() Foundation

Determines whether a valid date was entered.

Syntax
:badDate() --> lNoValidDate
Return

When a Get object has input focus and is editing a date value, the method :badDate() returns .T. (true) when the value of the edit buffer is an invalid date. In all other situations :badDate()returns .F. (false).

Description

When inputting dates, the method :badDate() tests whether the date input is valid. So, for example, if a user enters "04/31/94" or "02/29/94", :badDate() returns .T. since the month of April has only 30 days and the year 1994 was not a leap year. When :badDate() returns .T., it acts like a validation code block and does not permit the user to leave the field until a valid date is entered.

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.