Key Macros

Overview


Macro keys give the POSey Register system a great deal of power and
versatility.__A macro key may be used to store a series of keystrokes, thus
allowing the register to be customized and automated.

Macros may also be run from the Register Report Menu.__The system requires a
PC compatible computer keyboard to invoke a macro from this menu.__This
macro capability allows users to get reports or perform other automated
tasks from a back-office machine on the network.

Creating And Editing Macros


Macros can be assigned to POS keyboard or touch-screen keys using the Key
Programming program located in the Inventory menu section.__Assigning a
function code of 50 to a key will program it as a Macro Key.__Macro keys may
be linked to other keys, and may be designed just like any other Register
key.__However, part of the key programming for a Macro key involves entering
a list of keys (or other special macro functions) that the Macro key will
execute when it is pressed.

The set of macro instructions associated with a Macro key may be edited at
any time using the Edit Macros program in the Inventory menu section.__You
may also create new macros with this program.__This allows you to make
macros which can only be invoked by a multi-macro key (key function 56) or
from the register reports menu.

+--------------------------------------------------------------------------------+
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
||||+-------------------------| Macro Programming |--------------------------+||||
|||||________________________________________________________________________|||||
|||||________________Keymap #:_____________Key Number:_______________________|||||
|||||________________________________________________________________________|||||
|||||__Macro:________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
|||||________________________________________________________________________|||||
||||+------------------------------------------------------------------------+||||
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|_______F1ùScn Hlp F3ùClr Scn F4ùClr Fld F7ùRecord F8ùShow F9ùDel F10ùSave_______|
+--------------------------------------------------------------------------------+

Edit Macros Screen


The Edit Macros program entry screen shown above is the same entry screen
used when programming a Macro key.__During key programming, the menu level
and key number will automatically be filled in with the information for the
key you are programming.__When using the Macro Editor program, you must tell
the program which menu level and key number will be used for the macro.

Macros which are associated with a Macro key, or those which will be called
by a Multi-Macro key, must have a menu level of 0 to 999.__Since it would be
potentially harmful to attempt to run a macro designed to be invoked by the
Register from the Register Report menu, and vice-versa, menu level 1000 is
reserved for macros called from the Register Report menu.

A macro assigned to menu level 1000 cannot be accessed by a Register Macro
key.__And the Register Report menu will only run macros assigned to menu
level 1000.__Level 1000 macros can, however, change to menu levels 0 thru
999 to execute POS key functions (but you cannot then switch back to level
1000).

The macro entry screen allows you to program up to 50 key numbers or special
macro codes in a macro.__If additional steps are required, macros may call
another macro.__In order to be executed by a macro, a key must be located on
the current menu level.__If keys from other menu levels need to be included
in a macro, a special macro code is provided to switch menu levels.

While editing a macro, there are several special features of the program
which may come in handy;

____*___F8 allows you to view the expanded macro information in a window.
________Hitting F8 again will print the expanded information to the
________printer (or append it to the file "MACROS.LST" if the printer
________is not on-line). The function of keys when outside the register
________is not always known (we display as best we can).

____*___F11 allows you to insert a new key at the current cursor location.
________All keys starting at the cursor location are shifted right and
________the inserted key defaults to 0.

____*___Blanking a key number field and hitting the ENTER key will shift all
________keys following the cursor location to the left (deleting the
________blanked key) and leave the cursor at the same field (to allow
________deletion of a sequence of keys).

____*___F7 will enter the Record mode.__The default touch menu will be
________displayed and any keys selected will be inserted at the current
________cursor location and advance the cursor to the next field.__You
________will not see the key numbers until you exit Record mode.__If you
________change to a new touch menu and select keys, the change menu codes
________(-99 and menu level) will automatically be inserted. If you need to
________insert keys not on the menu (such as special keys or codes used to
________leave and re-enter the register) you can either hit any key as a
________"placeholder" to be changed later, or insert these keys later with
________the F11 option described above.

________Use the ESCape key on a keyboard to exit Record mode.

One thing that may be hard to grasp when programming a macro is that the
codes entered into the macro are key numbers ... not key functions.__So if
you need a macro to enter a clerk number, say "123" ... the macro codes you
enter must be the key numbers for the "1" Numeric key, the "2" Numeric key,
and the "3" Numeric key.__These numbers may not be the codes 1, 2, 3.

For this reason, we suggest that whenever you set up a touch-screen menu
level that will have a numeric keypad, be sure to program key number 1 as
the Numeric "1" key, key number 2 as the Numeric "2" key, and so forth.
This makes it more intuitive when programming macros.__Of course you do not
have this liberty when programming a standard POS keyboard.

Special Macro Codes


When programming a macro, several special macro codes are available, in
addition to the normal key number codes.__These macro codes perform special
functions when the macro executes.__They are described below;

____-95_____Defaults to the clerk ID of the last clerk logged into the
____________Register.__This code is used when a macro exits the Register to
____________run a report from the Register Report menu.__It allows a single
____________macro key to be used by all clerks.__This special code will be
____________ignored in the macro unless it occurs at a place in the macro
____________where a clerk logon is expected.

____-96_____Defaults to the password of the last clerk logged into the
____________Register.__This code is used when a macro exits the Register to
____________run any report requiring a password entry.__It prevents a clerk
____________from running a report he is not authorized to run.__This special
____________code will be ignored in the macro unless it occurs at a place in
____________the macro where a password is expected.

____-97_____Prompt for user input (applies to either clerk ID or password
____________entry).__When the input is terminated by the ENTER key the macro
____________processing is resumed.__This is used when a macro exits from the
____________Register and you want to allow the user to enter a password.
____________This allows a manager to use a macro to run a report even if the
____________clerk currently logged in is not authorized to run it.__It
____________should ALWAYS be used if Z-reports are run using macros to allow
____________the user to cancel the request if it was made accidentally.

____-98_____Skip here on error.__There should be one of these associated
____________with each key code of -95, -96, or -97 (i.e. if both -95 and -96
____________are used, there should be two -98 codes).__If the user cancels
____________input (ESCape key), the clerk ID is invalid, or the password is
____________invalid or does not have the required privileges, the macro will
____________skip to the associated -98 key and proceed from the next key. If
____________no -98 key is found the macro will end.

____-99_____Change to new menu level.__The new menu level must be specified
____________in the following entry, and must be in the range of 0 to 999.
____________Note that this macro code only causes the keymap level to change
____________with regard to key functions.__On touch-screen systems, the
____________screen image of the menu level will remain unchanged until, or
____________unless, a Menu Level Shift key is executed by the macro.__It is
____________not necessary for the screen menu image to match the level being
____________accessed by the macro.__However, if the macro exits at a
____________different level than where it began, it is important to use a
____________Menu Level Shift key in the macro to make sure the screen image
____________matches the key programming.

Register Macro Example


Following is an example of a Register macro.__For this example, we will
assume that the menu level of the Macro key contains the following
programmed keys;

____Key Number______Key Function

____50______________"0" Numeric key
____51______________"1" Numeric key
____52______________"2" Numeric key
____53______________"3" Numeric key
____58______________"8" Numeric key
____59______________"9" Numeric key
____66______________Cash key
____10______________Clear key
____11______________Inquiry key

The following macro will exit the Register, print a System X report, and
then re-enter the Register.

____Code____Description of Action

____11______Inquiry key
____11______Inquiry key
____10______Clear (we are now at the logon screen)
____2_______Choose to logoff Register (we are now at Register Report menu)
____52______"2" (select system report)
____-96_____Enter password of clerk logged onto Register
____51______"1" (select X report)
____51______"1" (select All)
____59______"9" (turn off screen output)
____58______"8" (select printer output)
____59______"9" (turn off file1 output)
____59______"9" (turn off file2 output)
____50______"0" (accept output device selection)

____________Report begins printing...
____________When done, we are returned to the Register Report menu

____-98_____Skip here if invalid clerk password
____51______"1" (Start Cash Register, logon screen is displayed)
____1_______Choose to logon to the Register
____-95_____Enter clerk number of clerk last logged on
____66______Cash key to complete logon

Macro Codes At Selection Screens


There are a number of cases where a special selection screen will be
displayed.__These screens have their own special key numbers which must be
used when programming a macro.

A good example of this was shown above, where the Register logon box was
displayed on the screen.__When the logon box is displayed, only two keys are
valid for macro codes;

____1___Logon
____2___Logoff

There are other selection screens or selection boxes which may be displayed
by the POSey Register when used with a touch-screen, light pen, or mouse.
Following is a summary of the screen types you may encounter, and the
macro codes required to select the keys on these screens.__Note that many of
these key groupings will only make up a part of a larger entry screen on the
Register.

____+-----------------+
____| Accept | Escape |
____|________| (Exit) |
____+-----------------+


____1_______Accept
____2_______Escape

____+-----------------------------------+
____|__Page__|__Page__| Accept | Escape |
____|___Up___|__Down__|________| (Exit) |
____+-----------------------------------+


____1_______Page Up
____2_______Page Down
____3_______Accept
____4_______Escape

____+--------------------------------------------+
____|__Page__|__Page__|__Open__| Create | Escape |
____|___Up___|__Down__|__Check | Check__| (Exit) |
____+--------------------------------------------+


____1_______Page Up
____2_______Page Down
____3_______Open Check
____4_______Create Check
____5_______Escape

____+--------------------------------------------+
____|__Page__|__Page__|__Open__| Select | Escape |
____|___Up___|__Down__|__Check |__All___| (Exit) |
____+--------------------------------------------+


____1_______Page Up
____2_______Page Down
____3_______Open Check
____4_______Select All
____5_______Escape

____+--------------------------------------------+
____|__Page__|__Page__|__Void__| Void___| Escape |
____|___Up___|__Down__|__Item__| Trans. | (Exit) |
____+--------------------------------------------+


____1_______Page Up
____2_______Page Down
____3_______Void Item
____4_______Void Trans.
____5_______Escape

____+--------------------------+
____|__Page__|__Page__| Escape |
____|___Up___|__Down__| (Exit) |
____+--------------------------+


____1_______Page Up
____2_______Page Down
____3_______Escape

____+----------------------------------------------------------------------------+
____|__1___|__2___|__3___|__4___|__5___|__6___|__7___|__8___|__9___|__0___|Escape|
____|______|______|______|______|______|______|______|______|______|______|(Exit)|
____|------+------+------+------+------+------+------+------+------+------+------|
____|__Q___|__W___|__E___|__R___|__T___|__Y___|__U___|__I___|__O___|__P___| Save |
____|______|______|______|______|______|______|______|______|______|______|______|
____|------+------+------+------+------+------+------+------+------+------+------|
____|__A___|__S___|__D___|__F___|__G___|__H___|__J___|__K___|__L___|__-___| Back |
____|______|______|______|______|______|______|______|______|______|______| Space|
____|------+------+------+------+------+------+------+------+------+------+------|
____|__Z___|__X___|__C___|__V___|__B___|__N___|__M___|___,__|__.___| Space| Enter|
____|______|______|______|______|______|______|______|______|______|______|______|
____+----------------------------------------------------------------------------+


____1_______"1"_________12______"Q"_________23______"A"_________34______"Z"
____2_______"2"_________13______"W"_________24______"S"_________35______"X"
____3_______"3"_________14______"E"_________25______"D"_________36______"C"
____4_______"4"_________15______"R"_________26______"F"_________37______"V"
____5_______"5"_________16______"T"_________27______"G"_________38______"B"
____6_______"6"_________17______"Y"_________28______"H"_________39______"N"
____7_______"7"_________18______"U"_________29______"J"_________40______"M"
____8_______"8"_________19______"I"_________30______"K"_________41______","
____9_______"9"_________20______"O"_________31______"L"_________42______"."
____10______"0"_________21______"P"_________32______"-"_________43______Space
____11______Escape______22______Save________33______Backspace___44______Enter

____+---------------------------+
____|___|___________________|___|
____|___|___________________|___|
____|---------------------------|
____|__7___|__8___|__9___| BACK |
____|______|______|______| SPACE|
____|------+------+------+------|
____|__4___|__5___|__6___| CLEAR|
____|______|______|______| ENTRY|
____|------+------+------+------|
____|__1___|__2___|__3___|______|
____|______|______|______|______|
____|------+------+------+------|
____|__0___|__00__|__.___| ENTER|
____|______|______|______|______|
____+---------------------------+


____1_______"7"_________9_______"1"
____2_______"8"_________10______"2"
____3_______"9"_________11______"3"
____4_______Backspace___12______Space
____5_______"4"_________13______"0"
____6_______"5"_________14______"00"
____7_______"6"_________15______"."
____8_______Clear_______16______Enter

____+----------------------------------+
____|__7___|__8___|__9___| BACK |ESCAPE|
____|______|______|______| SPACE| EXIT |
____|------+------+------+------+------|
____|__4___|__5___|__6___|__UP__| SAVE |
____|______|______|______|______|(DONE)|
____|------+------+------+------+------|
____|__1___|__2___|__3___| DOWN |______|
____|______|______|______|______|______|
____|------+------+------+------+------|
____|__0___|__00__|______| CLEAR| ENTER|
____|______|______|______| ENTRY|______|
____+----------------------------------+


____1_______"7"_________6_______"4"_________11______"1"_________16______"0"
____2_______"8"_________7_______"5"_________12______"2"_________17______"00"
____3_______"9"_________8_______"6"_________13______"3"
____4_______Backspace___9_______Up__________14______Down________19______Clear
____5_______Escape______10______Save____________________________20______Enter

____+---------------------------+
____|___|___________________|___|
____|___|___________________|___|
____|---------------------------|
____|__7___|__8___|__9___| BACK |
____|______|______|______| SPACE|
____|------+------+------+------|
____|__4___|__5___|__6___| CLEAR|
____|______|______|______| ENTRY|
____|------+------+------+------|
____|__1___|__2___|__3___|CANCEL|
____|______|______|______| CARD |
____|------+------+------+------|
____|__0___|__00__|__.___| ENTER|
____|______|______|______|______|
____+---------------------------+


____1_______"7"_________9_______"1"
____2_______"8"_________10______"2"
____3_______"9"_________11______"3"
____4_______Backspace___12______Cancel Card
____5_______"4"_________13______"0"
____6_______"5"_________14______"00"
____7_______"6"_________15______"."
____8_______Clear_______16______Enter


Selection screens not described above cannot be controlled through the use
of a Register macro.

Running Macros from the Register Report Menu

___
Macros may also be run from the Register Report menu.__A PC compatible
keyboard is required to invoke a macro from this menu.
___
The register report menu will only run macros assigned to menu level 1000.
These macros can, however, change to menu levels 0 thru 999 to execute POS
key functions (but you cannot then switch back to 1000).

To start execution of a macro from the register report menu, hit the F2
function key on your PC keyboard.__The system will request the desired macro
number.__The ESCape key may be used to cancel the request.__If a valid
number in the range 0 to 999 is entered and a macro with that key number
exists in menu level 1000 the macro will be executed.

Note that you cannot assign POS key functions to menu level 1000.__The key
values entered for a level 1000 macro are interpreted as PC keyboard keys
and must be in the range 0 thru 255.__Therefore, the numeral '1' would be
key number 49, the letter 'A' would be 65, etc.__Consult an ascii conversion
table if necessary.__Since numeric values (0-9) are most commonly used in
these macros, key numbers 0 thru 9 are interpreted as numeric 0 thru 9,
making the macro easier to enter and interpret.

NOTE: The special macro codes -95 and -96 (described above) may not be used
in a macro started from the register report menu.__These codes are used to
retrieve the clerk ID and password for the last clerk logged onto the
register.__Since the macro is not started from the register, this clerk info
is not available.__However, special macro code -97 may be used to require
the user to enter a password or clerk ID.__You should NEVER use a Master
password in a macro.__Instead, use a password limited to running the
specified report.__You should ALWAYS require password input for running Z
reports!!

Here is an example of how to set up a Register Report macro that will print
a System X report;

____Code____Description of Action

____2_______"2" (select system report)
____2_______"1"
____3_______"2"
____4_______"3"
____5_______"4" (enters password "1234")
____13______Trailing carriage return
____1_______"1" select X report
____1_______"1" select All
____0_______"0" accept default output device

____________Report begins printing...

Here's another example of how to create a Register Report macro which will
automatically log clerk "123" onto the register;

____Code____Description of Action

____1_______"1" (select to start register)
____-99_____Change menu level,
____0___________to level 0 which contains a numeric keypad on touch-screen
____1_______Choose to logon to register
____51______"1" (enter clerk ID)
____52______"2"____(assumes that these are menu level 0 key numbers
____53______"3"_____for "1", "2", and "3")
____66______Cash key to complete logon