HP Data Entry and Forms Management System (VPLUS) Reference Manual (32209-90024)
238 Chapter6
USING VPLUS INTRINSICS
COMMUNICATION AREA
language
to the code for the programming language you are using. If you are coding in
BASIC, you must set
usrbuflen
to the number of two-byte words needed for the comarea
extension. This value is displayed on the forms file listing generated by FORMSPEC.
Finally, in order to provide for possible future extensions to
comarea
, set
comarealen
to its
current total length.
Parameters
cstatus
Two-byte integer to which the intrinsic status is returned. Set to zero if the
call is successful; to a nonzero value if an error occurs. If the error is an
MPE file error, a file error number is also returned to
filerrnum
(Refer to
Appendix B for a list of the error codes that may be returned to
cstatus
with their meaning.) It is up to the user to provide error-handling routines
and to reset
cstatus
.
language
Two-byte integer that indicates the programming language of the calling
program:
• 0 = COBOL II/III
• 1 = BASIC
• 2 = FORTRAN 66
• 3 = SPL
• 5 = PASCAL//HP FORTRAN 77//HP BUSINESS BASIC //C/XL
The
language
must be set by the calling program before any intrinsic is
called.
comarealen
Two-byte integer that indicates the total length of
comarea
(use 6 0 for
terminals; 85 for data capture devices). The
comarealen
should be
specified for each
comarea
to simplify future changes to the length of
comarea
.
usrbuflen
For BASIC programs only,
usrbuflen
must be set to the number of
two-byte words to be appended to
comarea
for the form and data buffers
and internal tables. (Note that the number of bytes required for this
extension is printed when a form is listed through FORMSPEC.) The
usrbuflen
need not be set by other languages since VPLUS automatically
uses the DL area for buffers and internal tables. The
usrbuflen
does not
include the
comarea
length specified in
comarealen
, but it must be
contiguous to and immediately follow
comarea
.
cmode
Indicates whether current mode of data entry is collect.
• 0 = Collect Mode
• 1 = Browse Mode
If you want to save the form sequence for $RETURN, you must set
cmode
to
zero before calling VGETNEXTFORM.
lastkey
Two-byte integer set to a number between -256 and 26 (or -999) by
VREADFIELDS to indicate user response, which can be
ENTER or the last