TdxMessageDialogForm.SetPosition(Integer,Integer) Method
Moves the message dialog box to the specified position.
Declaration
procedure SetPosition(X: Integer; Y: Integer); virtual;
Parameters
Name | Type | Description |
---|---|---|
X | Integer | The horizontal offset (in pixels) of the upper-left dialog corner from the upper-left screen corner.
|
Y | Integer | The vertical offset (in pixels) of the upper-left dialog corner from the upper-left screen corner.
|
Remarks
A message box is centered on top of its owner window. The message box is centered on the screen if no owner window is specified.
Call the SetPosition
procedure to move the message box to any position on the screen.
Limitation
You can call the SetPosition
procedure and pass -1
as X
and Y
parameters to restore the default position of the message box only before it is displayed for the first time.