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

# TMessageBoxFunction

The type used for the MessageBox variable.

## Declaration

Source position: forms.pp line 1994

`type TMessageBoxFunction = function(`
`Text: PChar;`
`Caption: PChar;`
`Flags: LongInt`
`):Integer;`

## Arguments

`Text` |  | Main content for the message dialog.
`Caption` |  | Title displayed on the message dialog.
`Flags` |  | Numeric flag value for the buttons and icons displayed on the message dialog.

## Function result

Modal result from the message dialog routine.

## Description

TMessageBoxFunction is an Integer function type which specifies the routine used to perform a message box or dialog.

Arguments passed to the function identify the content for the message dialog, including:

- Text displayed in the message dialog
- Title used on dialog form
- Flag values that control the buttons and icon for the dialog

The return value contains the modal result returned from the message dialog.

## See also

MessageBoxFunction |  | Provides the routine used to display a message dialog in widgetset implementations.