command. You can redefine the keys from BASIC programs, or
change them at any time in direct mode. A situation where you
might want to redefine a function key is when you use a
command frequently, and want to save time instead of repeatedly
typing in the command. The new definitions are erased when you
turn off your computer. You can redefine any of the function keys
and as many times as you want.
If you want to reprogram the F7 function key to return you to text
mode from high-resolution or multicolor-graphic modes, for
example, you would use the key command in this fashion:
KEY 7,“GRAPHIC 0” + CHR$(13)
CHR$(13) is the ASCII code character for RETURN. So when you
press the F7 key after redefining the key, what happens is the
command “GRAPHIC 0” is automatically typed out and entered
into the computer with RETURN. Entire commands or series of
commands may be assigned to a function key.
Other keys used in C128 Mode only
Help
As noted previously, when you make an error in a program, your
computer displays an error message to tell you what you did
wrong. These error messages are further explained in Appendix
A of this manual. You can get more assistance with errors by
using the HELP key. After an error message, press the HELP key
to locate the exact point where the error occurred. When you
press HELP, the line with the error is highlighted on the screen in
reverse video (in 40 column) or underlined (in 80 column output).
For example:
7SYNTAX ERROR IN LINE 10 Your computer displays this.
HELP You press HELP.
10 PRONT “COMMODORE COMPUTERS” The line with the
mistake is high lighted in reverse if in 40 column output or under
lined in 80 column output.
5-18