Maps a wide character string to a narrow character string
Syntax
HRESULT WINAPI DupWideToAnsi (
LPCWSTR pwszString,
LPSTR* ppszStr
)
Parameters
- pwszString
- The source wide character string
- ppszStr
- A pointer to a pointer that receives the converted narrow character string
Return Value
S_OK on success or E_OUTOFMEMORY on fail
Remarks
The pointer returned in ppszStr must be freed with CoTaskMemFree when it's no longer needed
The wide to narrow conversion is done by SHUnicodeToAnsi
This function is also known as _DupWideToAnsi@8.