formhook CloseButton property
Return to Introduction  Previous page  Next page
Applies to
acFormHook component.  

Declaration
type  
  TacCloseButton = (cbEnabled, cbDisabled);  
 
property CloseButton: TacCloseButton;  

Description
The CloseButton property controls whether close button on form taskbar enabled (if CloseButton is cbEnabled) or disabled (if CloseButton is cbDisabled).  

Snapshot (close button is disabled)
closedisabled  

Note
iiwarning Even if CloseButton is cbDisabled, this will not prevent your form from closing (in example, on Alt+F4, or Ctrl+F4 for MDI childs). If you really would like to prevent closing, you must handle OnCloseQuery event in your forms.