Appendix A: System Routines — Dialog
353
TI
-
89 / TI
-
92 Plus Developer Guide
Not for Distribution
Beta Version January 26, 2001
DlgMessage
Declaration:
WORD
DlgMessage
(const char *
Title
, const char *
Message
,
WORD
lButton
, WORD
rButton
)
Category(ies):
Dialog
Description:
Issue a dialog with a given
Title
and a word-wrapped
Message
. The
Message
string may contain newline constants. The dialog box will be
sized to fit the screen with a predefined width for the TI
-
89 and the
TI
-
92 Plus.
Inputs:
Title
— String pointer for title of dialog box (no title if NULL).
Message
— String pointer message to be word wrapped in dialog
box.
lButton
,
rButton
— One of the predefined button constants: PDB_OK,
PDB_SAVE, PDB_YES, PDB_CANCEL, PDB_NO,
PDB_GOTO which define the buttons on the bottom
of the dialog box.
rButton
may be 0 if only one button
is needed.
Outputs:
KB_ENTER — User pressed
¸
to close dialog box.
KB_ESC — User pressed
N
to close dialog box.
Assumptions:
If there is not enough memory for the dialog box, a low memory version will
be used (no word wrapping); so this dialog will always succeed.
Side Effects:
May cause the heap to be compressed.
Availability:
All versions of the TI
-
89 / TI
-
92 Plus. However, on AMS 2.04 and higher,
word wrap also occurs on commas and spaces.
TI
-
89 / TI
-
92 Plus
Differences:
None
See Also: Dialog
Example:
if (KB_ENTER == DlgMessage("ERROR: Writing to setup file", "Delete setup file and
recreate it?", PDB_YES, PDB_NO))
FDelete( "ZSETUP" );