sprintfWithPointer
Copies the format string to the destination string with the format filled out as specified.
void sprintfWithPointer ( BYTE *destinationString, void *controlString, void *argumentVector );
As argument tokens are detected in the control string, the corresponding argument is extracted from the argument vector, and a string representation of that argument is inserted in the destination string (in place of the argument token).
Each argument in the argument vector is a 32-bit object. Each element of this vector is cast differently, as it is extracted, depending on the corresponding token that is detected in the control string.
For tokens indicating double LONG numeric values, the two adjacent 32-bit objects are treated as the double LONG value. The first 32-bit value represents the least significant 32-bit portion, and the second 32-bit value represents the most significant 32-bit portion.
For string tokens, the corresponding 32-bit object is cast as pointer to BYTE.
The following example demonstrates sprintfWithPointer:
BYTE dString[256]; LONG vector[3]; vector[0]=(LONG) "George"; vector[1]=48; vector[2]=0x12345; sprintfWithPointer(dString, "Hello, %s. You are %d and your code is %08X\r\n", vector); OutputToScreen(screenHandle, dString);