Vcl.Forms.TCloseQueryEvent

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

TCloseQueryEvent = procedure(Sender: TObject;
var CanClose: Boolean) of object;

C++

typedef void __fastcall (__closure *TCloseQueryEvent)(System::TObject* Sender, bool &CanClose);

Properties

Type Visibility Source Unit Parent
type
typedef
public
Vcl.Forms.pas
Vcl.Forms.hpp
Vcl.Forms Vcl.Forms

Description

TCloseQueryEvent is used for event handlers that are called when a window is about to close.

The TCloseQueryEvent type is the type for event handlers that allow an application to block the closing of a window (form or dialog).

Sender is the object whose event handler is called. This is the form that is about to close or the dialog whose window is about to close.

CanClose is set by the event handler to indicate whether the form or dialog can close (true) or whether the user should be blocked from closing it (false).

See Also