home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Hall of Fame
/
HallofFameCDROM.cdr
/
pcmag
/
key-fake.lzh
/
KEY-FAKE.DOC
< prev
Wrap
Text File
|
1988-11-24
|
3KB
|
70 lines
KEY-FAKE Charles Petzold
______________________________________________________
Purpose: Supplies the series of keystrokes needed to
initialize an application program on boot-up.
Format: KEY-FAKE ["xyz"] [nn] [0] [@F]
Programname
Characters typed within a pair of single or
double quotes ("xyz") are normal ASCII-
character keystrokes. Numbers (nn) not in
quote marks are ASCII decimal codes, e.g., 13
(Enter), 26 (Ctrl-Z), or 27 (Esc). Numbers
preceded by @ are the extended ASCII decimal
codes (128 through 255) generated by the Alt
keys, cursor keys, Ins and Del keys, and the
Function keys (e.g., @61 is the F3
keystroke). The 0 is used with programs that
check the keyboard buffer (it tells such
programs the buffer is clear, so the programs
will treat the succeeding keystroke
separately).
Remarks: KEY-FAKE is of greatest use in batch files
used to call up application programs. For
example, to enter Lotus's 1-2-3 and set it
for File Retrieve, the following .BAT file
would be appropriate:
CD \LOTUS
KEY-FAKE 0 13 0 13 0 13 0 13 0 13 "/FR"
LOTUS
This takes you past the necessary initial
carriage returns and /FR command without
having to type them in each time.
Similarly, if each time you enter BASICA you
want to have a blue border, blue background,
and yellow letters, you would create a batch
file, B.BAT, containing the lines
KEY-FAKE "COLOR 14,1,1" 13 "CLS" 13
BASICA
Notes:
1. The keystroke sequence stored by KEY-
FAKE is limited to 124 characters and
must be on one continuous command line.
Keystrokes not supported by PC BIOS
(e.g., Alt-Home) cannot be stored.
2. Programs such as XyWrite II that get
keyboard information directly from the
hardware keyboard interrupt will bypass
KEY-FAKE. KEY-FAKE will also not work
well when you are on-line using a
communications program.
3. KEY-FAKE is memory resident, but can be
executed multiple times in the same
session without reloading. However, if
nested batch files cause it to be re-
invoked before its initially stored
keystroke sequence has been exhausted,
the remaining initial keystrokes will be
lost.