Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Converts an item identifier list to a file system path. This function extends SHGetPathFromIDList by allowing you to set the initial size of the string buffer and declare the options below.
BOOL SHGetPathFromIDListEx(
[in] PCIDLIST_ABSOLUTE pidl,
[out] PWSTR pszPath,
DWORD cchPath,
GPFIDL_FLAGS uOpts
);
[in] pidl
Type: PCIDLIST_ABSOLUTE
A pointer to an item identifier list that specifies a file or directory location relative to the root of the namespace (the desktop).
[out] pszPath
Type: PWSTR
When this function is called it is passed a null-terminated, Unicode buffer to receive the file system path. This buffer is of size cchPath.
When this function returns, contains the address of a null-terminated, Unicode buffer that contains the file system path. This buffer is of size cchPath.
cchPath
Type: DWORD
The size of the buffer pointed to by pszPath, in characters.
uOpts
Type: GPFIDL_FLAGS
These flags determine the type of path returned.
Win32 file names, servers, and root drives are included.
Uses short file names.
Include UNC printer names items.
Type: BOOL
Returns TRUE if successful; otherwise, FALSE.
Except for UNC printer names, if the location specified by the pidl parameter is not part of the file system, this function fails.
If the pidl parameter specifies a shortcut, the pszPath contains the path to the shortcut, not to the shortcut's target.
Requirement | Value |
---|---|
Minimum supported client | Windows Vista [desktop apps only] |
Minimum supported server | Windows Server 2008 [desktop apps only] |
Target Platform | Windows |
Header | shlobj_core.h (include Shlobj.h) |
Library | Shell32.lib |
DLL | Shell32.dll |
API set | ext-ms-win-shell-shell32-l1-2-2 (introduced in Windows 10, version 10.0.14393) |