Show pageOld revisionsBacklinksBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ====== INPUT.CHAR ====== ^Published By^Date^Version^Knowledge Level^Keywords^ |Revelation Technologies|14 NOV 1989|2.X|EXPERT|INPUT.CHAR, | ==== Description ==== INPUT.CHAR is the fundamental subroutine in Advanced Revelation for processing keyboard input. INPUT.CHAR processes a single keystroke (or function key), returning only when a key is pressed. All keystrokes are processed except those defined as priority interrupts in @PRIORITY.INT (see Appendix 1, System Variables). User environment restrictions may also apply to certain keys. These are defined in @ENVIRON.SET (see Appendix 1). INPUT.CHAR is also the basis for the indexing timeout loop, used to determine when background indexing is to occur. ==== Arguments ==== === key === An optional variable used by INPUT.CHAR to return the ASCII code for the keystroke entered by the user ==== Values returned ==== If specified, key contains the ASCII coded keystroke. This is a two-character ASCII sequence (the initial value is 0) if a function key is pressed. ==== Examples ==== <code> *Initialization DECLARE SUBROUTINE INPUT.CHAR,MSG *Display the ASCII code for the keystroke CHARACTER = '' IMAGE = '' MSG('Please enter a character:','UB',IMAGE,'') INPUT.CHAR(CHARACTER) IF LEN(CHARACTER) >> 1 THEN *The key pressed was a function key or function key sequence. CHAR1 = SEQ(CHARACTER[1,1]) CHAR2 = SEQ(CHARACTER[2,1]) CHARACTER = CHAR1:' ':CHAR2 END ELSE CHARACTER = SEQ(CHARACTER) END MSG('The ASCII code for the keystroke entered is: %1%','','', CHARACTER) MSG('','DB',IMAGE,'') </code> tips/revmedia/subs12.txt Last modified: 2024/06/19 20:20by 127.0.0.1