1 | Source buffer handle | Input | Binary(4) |
2 | Target buffer handle | Input | Binary(4) |
3 | Error code | I/O | Char(*) |
Return code | Output | Binary(4) |
The Copy Buffer (QsnCpyBuf) API copies the contents of one buffer to another buffer. Both buffers must be the same type--command or input. If the target and source buffers are the same, no operation takes place and no error is reported.
If a target command buffer contains data, the data in the source buffer is appended to the target buffer. A CPFA301 error is issued if the target command buffer is not large enough to hold the contents of the source buffer and cannot be resized.
If input buffers are being copied, the target buffer must be empty. If the target input buffer is not large enough to hold the data from the source buffer, the data is truncated and no error is reported.
None
A handle for the buffer from which data is to be copied. The contents of this buffer are not affected by this operation.
A handle for the buffer to which data is to be copied.
The structure in which to return error information. For the format of the structure, see Error Code Parameter. If this parameter is omitted, diagnostic and escape messages are issued to the application.
A return code indicating the result of the operation. The value returned will be 0 if the operation was successful, or -1 otherwise.
Message ID | Error Message Text |
---|---|
CPF24B4 E | Severe error while addressing parameter list. |
CPF3CF1 E | Error code parameter not valid. |
CPF3CF2 E | Error(s) occurred during running of &1 API. |
CPFA305 E | Cannot add operation to command buffer. |
CPFA301 E | Command buffer is full. |
CPFA313 E | Command buffer already contains an input operation. |
CPFA31E E | Required parameter &1 omitted. |
CPFA330 E | Buffer type mismatch. |
CPFA331 E | Buffer handle incorrect. |
Top | Dynamic Screen Manager APIs | APIs by category |