Displays the form as a modal Dialog.
Source position: forms.pp line 667
public function TCustomForm.ShowModal: Integer; virtual; |
The modal result for the dialog.
Shows the form in a modal state and waits until it is closed by the user or by the program. Modal state means that neither the user nor the program can switch to another form already made visible before calling ShowModal.
The form must have Visible set to False when calling ShowModal. The call does not return until the form is closed. The application switches to modal state until ShowModal has completed.
ShowModal creates its own event loop using ProcessMessages.
Raises an EInvalidOperation exception if the form cannot be displayed as a modal form.