<< AddToDrawing | Align >> |
Top: Documentation Library | Up: A Commands |
AlertRequester Dialog Box Command
Display a message to the user.
button = AlertRequester (type/k, message/s, buttons/s)
Parameters:
type/k is a keyword of [ERROR|WARNING|NOTE|QUESTION], where ERROR is the default. Type influences the imagery in the alert.
message/s is the string to display.
buttons/s is a list of button strings seperated by a vertical bar.
Results:
returns the index into buttons parameter of the button pressed. First entry is 0.
Notes:
Python users can use the AlertType_Error, AlertType_Warning|AlertType_Warn, AlertType_Note, or AlertType_Question keys for type.
See Also:
AppendListString, CloseResource, CreateLanguageEngineList, CreateList, CreateRequester, DoLanguageEngineFormatDate, DoLanguageEngineLocalizeString, DoRequester, FreeLanguageEngineList, FreeList, FreeRequester, GetCmdStringFromCoord, GetControlAttr, GetCoordFromString, GetFolderPath, GetResourceString, GetUIStringFromCoord, OpenResource, PrependListString, SetControlAttr, SortList
Examples:
Additional example in ''RequesterExample.py''.
Python:
ARexx:
Applescript:
AlertRequester Command Definition url:PGScmd/alertrequester
created:2006-05-04 17:22:21 last updated:2006-09-14 09:42:21
Copyright © 1985-2024 GrasshopperLLC. All Rights Reserved.
User Contributed Comments For AlertRequester | sign in to add a comment |
Tim Doty wrote... | 2006-05-27 08:36:52 |
There's a formatting bug in the command: Notes: Python users can use the AlertType_Error, AlertType_Warning, AlertType_Warn, AlertType_Note, or AlertType_Question keys for type. Also, when using multiple buttons they are numbered from right to left instead of the expected left to right. For example, Python: result = AlertRequester(AlertType_Question, GetResourceString(rscH, 101, 3)['.result'], "Cancel|OK") if result['.result'] == 0: # do some action displays the buttons as Cancel then OK, but Cancel is index 1 and OK is index 0. | |
User Contributed Comments For AlertRequester | sign in to add a comment |
<< AddToDrawing | Align >> |
Top: Documentation Library | Up: A Commands |