LPSTR lstrcat(lpszString1, lpszString2) | |||||
LPSTR lpszString1; | /* address of buffer for concatenated strings | */ | |||
LPCSTR lpszString2; | /* address of string to add to string1 | */ |
The lstrcat function appends one string to another.
lpszString1
Points to a byte array containing a null-terminated string. The byte array containing the string must be large enough to contain both strings.
lpszString2
Points to the null-terminated string to be appended to the string specified in the lpszString1 parameter.
The return value points to lpszString1 if the function is successful.
Both strings must be less than 64K in size.
The following example uses the lstrcat function to append a test string to a buffer:
char szBuf[80] = { "the test string is " };
lstrcat(szBuf, lpsz);
MessageBox(hwnd, szBuf, "lstrcat", MB_OK);