Inserting comments in a library file, Writing an alias definition – HP NonStop G-Series User Manual

Page 79

Advertising
background image

Defining Function Keys and Writing Macros

Guardian User’s Guide 425266-001

5 -3

Creating a Library File for Your Function Keys

Inserting Comments in a Library File

You can add comments to your library file in three ways:

Begin a comment line with the COMMENT command.

Enclose the comment in braces ({ }). You can embed a braced comment in the
middle of a command.

Introduce the comment with two equal signs (==). A comment beginning with ==
must either begin a line or follow all other text on the line.

TACL ignores comments when you press a defined function key.

Writing an Alias Definition

An alias definition provides an alternate name for a TACL command. For example, the
F1 key can be an alias for the FILES command as shown in the example below.

To include comments in an alias definition, use braces ({ }) or double equal signs (==);
you cannot use the COMMENT command because this definition can contain only one
command.

These examples show alias key definitions for some frequently used commands:

?SECTION F1 ALIAS
FILES

?SECTION F2 ALIAS
FILE{Display information about my files}INFO

?SECTION F3 ALIAS
PERUSE
== Start PERUSE

?SECTION F4 ALIAS
FILENAMES
== Display file names

?SECTION F5 ALIAS
== Display the date and time
TIME

?SECTION SF16 ALIAS
LOGOFF

After you load these definitions, function keys F1 through F5 will be aliases for the
commands FILES, FILEINFO, PERUSE, FILENAMES, and TIME, respectively. SF16
is an alias for the LOGOFF command.

If the command included in an alias definition accepts command arguments, you can
enter values for these arguments when you use the function key, as described in

Passing

a Value to an Alias Definition

on page 5-7.

Advertising
This manual is related to the following products: