ILFree function

Frees an ITEMIDLIST structure allocated by the Shell.

Syntax

void ILFree(
  PIDLIST_RELATIVE pidl
);

Parameters

pidl

Type: PIDLIST_RELATIVE

A pointer to the ITEMIDLIST structure to be freed. This parameter can be NULL.

Return Value

This function does not return a value.

Remarks

ILFree is often used with ITEMIDLIST structures allocated by one of the other IL functions, but it can be used to free any such structure returned by the Shell—for example, the ITEMIDLIST structure returned by SHBrowseForFolder or used in a call to SHGetFolderLocation.

Note  When using Windows 2000 or later, use CoTaskMemFree rather than ILFree. ITEMIDLIST structures are always allocated with the Component Object Model (COM) task allocator on those platforms.
 

Requirements

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

See Also

ILAppendID

ILClone

ILCloneFirst

ILCombine