Share via


StrSafe.h Character-Count Functions

Send Feedback

The following functions use a character count rather than a byte count.

Strsafe.h function Replaces
StringCchCat
StringCchCatEx
Replace strcat, wcscat
StringCchCatN
StringCchCatNEx
Replace strncat
StringCchCopy
StringCchCopyEx
Replace strcpy, wcscpy
StringCchCopyN
StringCchCopyNEx
Replace strncpy
StringCchGets
StringCchGetsEx
Copy a line of text and replace gets, _getws
StringCchLength Used to ensure that a string is not larger than a given length. This function replaces strlen
StringCchPrintf
StringCchPrintfEx
Accept a format string and a list of arguments and return a formatted string. These functions replace sprintf, swprintf, wsprintf, _snprintf, _snwprintf
StringCchVPrintf
StringCchVPrintfEx
Accept a format string and its arguments, provided as a va_list, and return a formated string. These functions replace vsprintf, vswprintf, _vsnprintf, _vsnwprintf

See Also

Safe String Reference

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.