PathAddBackslashW function (shlwapi.h)
Adds a backslash to the end of a string to create the correct syntax for a path. If the source path already has a trailing backslash, no backslash will be added.
LPWSTR PathAddBackslashW( [in, out] LPWSTR pszPath );
[in, out] pszPath
A pointer to a buffer with a string that represents a path. The size of this buffer must be set to MAX_PATH to ensure that it is large enough to hold the returned string.
A pointer that, when this function returns successfully, points to the new string's terminating null character. If the backslash could not be appended due to inadequate buffer size, this value is NULL.
The shlwapi.h header defines PathAddBackslash as an alias which automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.
|Minimum supported client||Windows 2000 Professional, Windows XP [desktop apps only]|
|Minimum supported server||Windows 2000 Server [desktop apps only]|
|DLL||Shlwapi.dll (version 4.71 or later)|