User`s guide

cxxxii Contents
Query Communication Buffer Size—Function 122
This function allows the application to determine the maximum and optimum inbound and outbound
buffer size supported by the communications engine. These buffer sizes are to be used with the
Allocate Communications Buffer (123) function to optimize the performance of the structured field
functions.
Prerequisite Functions
None.
WinHLLAPI(QUERYCOMMBUFSIZ,lpbyString,lpwLength,
lpwReturnnCode)
Parameter Description
Data String A 9-byte string with the following format:
Byte 1 Short name session ID.
Bytes 2-9 Reserved.
Data Length Must be specified.
PS Position NA.
Parameter Description
Data String A 9-byte string with the following format:
Byte 1 Short name session ID.
Bytes 2-3 16-bit value indicating optimum inbound
buffer size.
Bytes 4-5 16-bit value indicating maximum inbound
buffer size.
Bytes 6-7 16-bit value indicating optimum outbound
buffer size.
Bytes 8-9 16-bit value indicating maximum outbound
buffer size.
Code Description
WHLLOK The function was successful.
WHLLNOTCONNECTED An invalid presentation space was specified, or was not
connected for window services.
WHLLPARAMETERERROR An invalid option was specified.
WHLLSYSERROR The function failed due to a system error.
WHLLNOTSUPPORTED The function is not supported by the emulation program.
The buffer sizes that are returned represent the record sizes transmitted across the communications
medium. For a DDM connection, the 8-byte header supplied in the Read and Write structured fields
data buffer is stripped off and 1 byte containing the structured field AID value is prefixed. The
application should compare the size of the actual data in the data buffer (which does not include the 8-
byte header) to the buffer sizes returned by the Query Communications Buffer Size function minus 1
Function Call
Call Parameters
Return Parameters
Return Codes
Remarks