The Keyboard Macro Script allows for the use of Toolbar commands in a Script. When the Scripted item is added to a transaction, Keystroke runs the macros listed in the Keyboard Macro window.
To set up a Keyboard Macro Script:
- Use the Type button to select Macro.
- Select the Key Macro button to display the Keyboard Macro entry box.
- Type the Keyboard Macro(s) into the entry box and press [F10] to Save or [Esc] to Cancel.
- Press [F10] or select the [OK] button to save the Script.
The Macros are identical to the commands used in the Toolbar Description box:
SalesEntryCommand - Perform various sales-related functions.
MessageBox - Display a message box with an OK button.
@Set - Change a Variable to be equal to a specified Value.
@ToggleFlag - Toggle the bit value of a variable.
PopUp - Pop up a Keystroke function.
RunMenu - Run a selected menu.
RunMacro - Run a macro.
Play - Play a sound file through Windows' sound system.
Run - Run another application or a DOS command.
RunDoc - Run another application or a DOS command in a new window.
Call - Run another application or a DOS command after the current process ends.
SendKeys - Create commands equivalent to pressing individual keys on the keyboard.
SecurityLevel - Set the Security Level required to use the Macro.
SecurityCheck - Set the Macro Security Level equal to that of a Keystroke function.
ToolBarOn - Display a Toolbar.
ToolBarOff - Hide a Toolbar.
ToolBarToggle - Toggle a Toolbar On or Off.
ToolBarOnTop - Place a Toolbar on top of another Toolbar.
Pause - Pause for a set number of seconds.
ChangeModule - Switch to another module.
RunReport - Run a Report Cue.
See: Keyboard Macro Example
Keyboard Macro Script Parameters:
Out of Stock Only - run script only if the Scripted Item is out of Stock (QOH<1).
Default Customer Only - run script only if the Customer is the Default Customer (the Default Customer is normally Customer 0 but can be changed in Configuration Manager, under the Settings Menu).
Returns Only - run script only if the quantity ordered/sold is negative (i.e. -1). The quantity must be entered before leaving the line item. Use [Tab] to navigate to the quantity field. Or use the Qty* entry method (-1*ProductCode).
Run Once Per Transaction - run script only once per transaction.
Not on New Trans - do not run script if the transaction is new.
Not on Edit Trans - do not run script if the transaction is being edited.
[Use On] - select the Transaction Type (or All Types) on which the script will run.
*[Advanced Restrictions] - run script only within any of the following restrictions (any of which may be combined): Date Range, Time Of Day, Day Of Week, Day Of Month, Min qty, Max Qty, Script Filter.
* - requires Keystroke Advanced license.
See:
Scripts Contents