Function _conGetCL() Foundation
Copies the value of a string container into a buffer.
XPPAPIRET _conGetCL(ContainerHandle chs, ULONG *ulCopy,
CHAR *pcBuffer, ULONG ulSize);
The function returns an error code (XPP_ERR_...) when the container chs is not a character string. If the return value is NULL, the operation was successful.
The function copies a container of character string type into a buffer. The copied string can contain NULL characters, however no NULL character is automatically written at the end of the copied character string.
/*
Copies the first 10 characters of a character string and then
terminates with a NULL character.
*/
#include <xppcon.h>
ContainerHandle hString;
XPPAPIRET xr;
CHAR buffer[11];
ULONG resultLen;
/* Assigns a value to... hString */
xr = _conGetCL(hString, &resultLen, buffer, sizeof(buffer)-1);
if (xr == 0)
{
/* Terminate with NULL character */
buffer[resultLen] = '\0';
/* ... Operations with the buffer */
}
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.