
IBM eNetwork Communications Server for Windows NT
Host Publisher Feature, Version 6.01
[Next|Previous|Contents]
Macro Language Introduction
What is a macro
A macro consists of one or more macro commands,
which do things like sending keystrokes to the host
and waiting for host data to be returned. Typically, you create
a macro by recording some interaction with a host session.
You can edit the recorded macro.
What are macros used for
Macros are used repeatedly in Host Access to connect, navigate
through the data loop and recognized screens, handle errors,
and log off. However,macros are
only used as one part of the design of a Host Access Integration
Object; the rest of the Integration object is also important.
Each macro can do two things:
- Wait for a screen
- Send keystrokes
No conditional processing is supported, except for the complete
failure of the macro if a timeout occurs. A macro cannot be used
by itself to react to different conditions.
Why learn about macros
You should learn about the macro language to get the most out
of the Host Access SIM. If you only use the macro recorder and never
modify the recorded macros, you are limited to the simplest
features of macros. The macro recorder can only use the simplest
features because it cannot know what you intend as you view screens
and press keys.
All recorded macros look at the cursor position on screens and
send fixed keystrokes. By editing macros, you can make them more
general or more specific in how they recognize screens, and you can
change fixed keystrokes to varied strings drawn from Web input forms or
Host Publisher session variables.
Editing macros
It is easiest to edit macros immediately after recording them.
Otherwise, you must make sure the macro is attached somewhere in the
integration object. Find the place where it is attached, and click
the Edit button. (You cannot edit the .HMF file directly, because it
is not a plain text file.)
Details
The following sections give more information about macros:
For more information
The macro language for Host Publisher is supplied by IBM's eNetwork
Host On-Demand Version 3.0.
The macro commands are a subset of the methods in IBM's
Host Access
Class Library. You can find more information in
the publication IBM eNetwork Personal Communications Version 4.2 for Windows 95 and Windows NT Host
Access Class Library, SC31-8527-00.
[Next|Previous|Contents]
IBM eNetwork Communications Server for Windows NT
Host Publisher Feature, Version 6.01