The Text Command

text.png

Command Summary

Displays a line of text in a dialog box.

Command Syntax

Text string of text

Menu Location

Starting in the program editor:

  • Press F3 to enter the I/O menu.
  • Press 1 to enter the Dialog submenu.
  • Press 1 to select Text.

Calculator Compatibility

This command works on all calculators.

Token Size

3 bytes

On its own, the Text command displays a simple dialog box with a line of text (left-aligned) inside. It can also be used inside a Dialog..EndDlog block, to add a line of text to a more advanced dialog.

The text must be a single string; but you can build one out of smaller strings and other data types using the & and string() commands.

Text will give an error if the string is too long — how long varies from model to model, and depending on if Text is being used inside or outside Dialog..EndDlog, but in general anything below 30 characters is safe (otherwise, you should test the dialog first to make sure everything fits). It uses the small, variable-width font on the TI-89 and TI-89 Titanium, and the normal fixed-width font on widescreen calculators.

Advanced Uses

You can add Text "" to a dialog to skip a line between two other elements.

Error Conditions

130 - Argument must be a string happens when Text is used to display other data types without using string() first.

230 - Dimension happens when the line of text is too long to fit in a dialog box.

Related Commands

See Also

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-Noncommercial 2.5 License.