StrRetToBuf
Other versions of this page are also available for the following:
8/28/2008
This function takes a STRRET structure returned by IShellFolder::GetDisplayNameOf, converts it to a string, and places the result in a buffer.
Syntax
HRESULT StrRetToBuf(
LPSTRRET pstr,
LPCITEMIDLIST pidl,
LPTSTR pszBuf,
UINT cchBuf
);
Parameters
- pstr
[in] Pointer to the STRRET structure. When the function returns, this pointer is no longer valid.
- pidl
[in] Pointer to the item's ITEMIDLIST structure.
- pszBuf
[out] Buffer to hold the display name. It is returned as a null-terminated string. If cchBuf is too small, the name is truncated to fit.
- cchBuf
[in] Size of pszBuf, in characters. If cchBuf is too small, the string is truncated to fit.
Return Value
Returns S_OK if successful, or an error code otherwise.
Remarks
If the uType member of the structure that pstr points to is set to STRRET_WSTR then the pOleStr member of that structure is freed on return.
Requirements
Header | shlwapi.h |
Library | ceshell.lib |
Windows Embedded CE | Windows CE .NET 4.2 and later |