IShellIconOverlayManager::GetFileOverlayInfo method (shlobj_core.h)

Gets the index of the icon overlay or the icon image for the specified file with the specified attributes.

Syntax

HRESULT GetFileOverlayInfo(
  [in]  PCWSTR pwszPath,
        DWORD  dwAttrib,
  [out] int    *pIndex,
        DWORD  dwflags
);

Parameters

[in] pwszPath

Type: PCWSTR

The full path of the file.

dwAttrib

Type: DWORD

The attributes of the file. This parameter can be a combination of any of the file attribute flags (FILE_ATTRIBUTE_*) defined in the Windows header files. See File Attribute Constants.

[out] pIndex

Type: int*

A pointer to the icon index in the system image list.

dwflags

Type: DWORD

For the index of the icon overlay, use SIOM_OVERLAYINDEX. For the index of the icon image, use SIOM_ICONINDEX.

Return value

Type: HRESULT

This method can return one of these values.

Return code Description
S_OK
The appropriate index was found.
E_FAIL
Failure for any reason.

Requirements

Requirement Value
Minimum supported client Windows 2000 Professional [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header shlobj_core.h
DLL Shell32.dll (version 5.0 or later)

See also

IShellIconOverlay

IShellIconOverlayManager