Description:
Globally overrides the default text for the message box buttons. This method only needs to be called once for each instance of PowerMessage that you create. This method will override the default button text. A call to of_SetButtonText will take precedence and will override the text set with this method.
Syntax:
of_setenumtext (string as_button1, button a_buttons)
of_setenumtext (string as_button1, string as_button2, button a_buttons)
of_setenumtext (string as_button1, string as_button2, string as_button3, button a_buttons)
Argument |
Description |
as_button1 |
Text that will display in the first button. |
as_button2 |
Text that will display in the second button. |
as_button3 |
Text that will display in the third button. |
a_buttons |
A value of the Button enumerated datatype indicating the set of CommandButtons you want to change the text of. The buttons are numbered in the order listed in the enumerated datatype. Values are: •OK! - (Default) OK button •OKCancel! - OK and Cancel buttons •YesNo! - Yes and No buttons •YesNoCancel! - Yes, No, and Cancel buttons •RetryCancel! - Retry and Cancel buttons •AbortRetryIgnore! - Abort, Retry, and Ignore buttons |
Return Value:
Always returns 1.
Usage:
Example 1; Localized Text:
//Set the text that will display for the first and second button any time you pass YesNoCancel! to the MessageBox function.
PowerMessage.of_SetEnumText("Oui", "Non", "Annuler", YesNoCancel!)
//Use YesNoCancel!, button text will display using the values passed in through the of_SetEnumText function
PowerMessage.MessageBox("Redémarrage de l'application requis", "L'application doit redémarrer pour appliquer les modifications.", YesNoCancel!, 1)
Copyright © 2021 Werysoft Inc.