Language Reference

KEYDEF

Description The KEYDEF command creates a key that executes a user-de￿ned function. The key can be a softkey that is located in the 4USER5 menu, or it can be

a key that is located on an unde￿ned custom keypad. The keys on the normal recognized keypad cannot be rede￿ned. Once a key is de￿ned, the user-de￿ned function is executed whenever the key is pressed.

Error 2013

Error 2013 is displayed if a user-de￿ned function is called in a KEYDEF before the function is de￿ned and stored.

Up to 14 user-de￿ned softkeys can be displayed at one time. They are all accessed with the 4USER5 key. The softkeys are numbered from 1 to 14. The following ￿gure shows the correspondence between softkey number and softkey location. The softkey label can be up to 14 characters long, but if longer than 7, the characters are divided into 2 lines of up to 7 characters each. Additional characters can be incorporated into the label for control codes. For example, a line feed may be used to specify which character begins the second line of the label. Use the READMENU command as another way to build menus of keys. Use the PROTECT command to prevent inadvertent erasure or rede￿nition. KEYPST protects key #8 automatically. Use PROTECT to turn o￿ the protection.

7-189