PA_OpenDialog



PA_OpenDialog (dialog; dialogName; closeBox) → PA_Dial4D

Parameter Type Description
dialog PA_Dial4D Dialog reference
dialogName char* Name of a dialog stored in plugin resource
closeBox char 1 = Has close box, 0 = No close box
Function result PA_Dial4D Dialog reference

Description

The routine PA_OpenDialog opens the dialog saved in plugin resource with name dialogName in a new window. If closeBox is 1, the window will have a close box. This resource is associated with the dialog context dialog .

PA_OpenDialog

returns the dialog reference context. If dialog is a dialog context, PA_OpenDialog returns it unchanged. If dialog is 0L, 4D creates a dialog context and returns it.

Please refer to the tutorial " 4D Dialogs : using a Form as a dialog " to learn how to save forms in plugin resources.

By default, dialogName needs to be a null terminated C string. If you have previously called PA_UsePStrings, you must pass a Pascal string to the command.

By default, dialogName needs to use Macintosh characters set on Macintosh, and ANSI characters set under Windows. You can call PA_UseMacCharacters or PA_UseAnsiCharacters to specifically use Macintosh or ANSI characters.

Example

See PA_NewDialog and 4D Dialogs : using a Form as a dialog for an example of use.

See Also

PA_CloseDialog , PA_ModalDialog , PA_NewDialog , PA_UseAnsiCharacters , PA_UseCStrings , PA_UseMacCharacters , PA_UsePStrings .

Error Handling

None.