ILCreateFromPath function

Returns the ITEMIDLIST structure associated with a specified file path.

Syntax

PIDLIST_ABSOLUTE ILCreateFromPath(
  PCTSTR pszPath
);

Parameters

pszPath

Type: PCTSTR

A pointer to a null-terminated Unicode string that contains the path. This string should be no more than MAX_PATH characters in length, including the terminating null character.

Return Value

Type: PIDLIST_ABSOLUTE

Returns a pointer to an ITEMIDLIST structure that corresponds to the path.

Remarks

Call ILFree to release the ITEMIDLIST when you are finished with it.

Requirements

   
Windows version Windows XP [desktop apps only] Windows Server 2003 [desktop apps only]
Target Platform Windows
Header shlobj_core.h (include Shlobj.h, Shlobj_core.h, Shlobj.h, Shlobj_core.h)
Library Shell32.lib
DLL Shell32.dll (version 5.0 or later)