Click or drag to resize

DialogWindow.EndDialog Method

X#
Remove this dialog window from view (passing control back to the routine which created the dialog window) and post a result code indicating how it was closed.

Namespace:  VO
Assembly:  VOGUIClasses (in VOGUIClasses.dll) Version: 2.19
Syntax
 VIRTUAL METHOD EndDialog(
	iResult
) AS USUAL CLIPPER
Request Example View Source

Parameters

iResult (Optional)
Type: Usual
The result code that should be posted. The default is 0.

Return Value

Type: Usual
Examples
Tip Tip
This result code can then be passed to the routine that called the dialog window if the routine invokes DialogWindow:Result.
The following example instructs EndDialog() to return 0 if the Cancel push button is pressed and 1 if OK is pressed:
X#
1METHOD ButtonClick(oEvent) CLASS MyDialogWindow
2IF oEvent:nControlID == ID_OK
3SELF:EndDialog(1)
4ENDIF
5IF oEvent:nControlID == ID_CANCEL
6SELF:EndDialog(0)
7ENDIF
See Also