[Overview][Constants][Types][Classes][Procedures and functions][Index] Reference for unit 'EditBtn' (#lcl)

TDateEdit.OnAcceptDate

Event handler signalled to accept or reject a new date value selected using the calendar dialog for the control.

Declaration

Source position: editbtn.pas line 641

published property TDateEdit.OnAcceptDate : TAcceptDateEvent
  read FOnAcceptDAte
  write FOnAcceptDate;

Description

OnAcceptDate is a TAcceptDateEvent property with the event handler signalled to accept or reject a new value for the Date property. The handler routine can perform actions to validate or update the TDateTime and Boolean arguments.

OnAcceptDate is signalled (when assigned) when the pop-up calendar dialog is displayed for the grouped edit control. The handler routine can update the value in the date argument if its value is not in an acceptable range. If the Boolean argument is True on exit from the handler, the date argument is stored to the Date property. Otherwise, the new date/time value is discarded.

An exception raised during execution of the pop-up calendar dialog is handled in the class instance; MessageDlg is called to display the exception message.

See also

TDateEdit.ButtonClick

  

Displays a pop-up calendar dialog when the Button for the grouped edit control is clicked.

TDateEdit.Date

  

Contains the TDateTime value for the control.

TAcceptDateEvent

  

TAcceptDateEvent - generic event handling method for accepting a date from a dialog.


Version 4.0 Generated 2025-05-03 Home