SHBindToFolderIDListParent function (shlobj_core.h)

Given a Shell namespace item specified in the form of a folder, and an item identifier list relative to that folder, this function binds to the parent of the namespace item and optionally returns a pointer to the final component of the item identifier list.

Syntax

SHSTDAPI SHBindToFolderIDListParent(
  [in, optional]  IShellFolder       *psfRoot,
  [in]            PCUIDLIST_RELATIVE pidl,
  [in]            REFIID             riid,
  [out]           void               **ppv,
  [out, optional] PCUITEMID_CHILD    *ppidlLast
);

Parameters

[in, optional] psfRoot

Type: IShellFolder*

A pointer to a Shell folder object. If psfRoot is NULL, indicates that the IDList passed is relative to the desktop.

[in] pidl

Type: PCUIDLIST_RELATIVE

A PIDL to bind to, relative to psfRoot. If psfRoot is NULL, this is an absolute IDList relative to the desktop folder.

[in] riid

Type: REFIID

Reference to the desired interface ID. This is typically IID_IShellFolder or IID_IShellFolder2, but can be anything supported by the target folder.

[out] ppv

Type: void**

When this function returns, contains the interface pointer requested in riid. This is typically IShellFolder or IShellFolder2, but can be anything supported by the target folder.

[out, optional] ppidlLast

Type: PCUITEMID_CHILD*

A pointer to the last ID of the pidl parameter, and is a child ID relative to the parent folder returned in ppv. This value can be NULL.

Return value

Type: HRESULT

If this function succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

Note  Calling the SHBindToFolderIDListParent function is equivalent to calling the SHBindToFolderIDListParentEx function with NULL as the bind context.
 

Requirements

   
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)
DLL Shell32.dll

See also

SHBindToFolderIDListParentEx