ImageList_WriteEx function (commctrl.h)

Writes an image list to a stream.

Syntax

HRESULT ImageList_WriteEx(
  [in] HIMAGELIST himl,
  [in] DWORD      dwFlags,
  [in] IStream    *pstm
);

Parameters

[in] himl

Type: HIMAGELIST

A handle to the image list.

[in] dwFlags

Type: DWORD

A flag that specifies how the stream is written.

Value Meaning
ILP_NORMAL
Writes to the stream using the file format for Common Controls 6.0, which includes information about image list attributes new to this version.
ILP_DOWNLEVEL
Writes to the stream using a file format previous to version 6.0. Specify this flag if you need to save image lists loaded under Common Controls versions earlier than version 6.0.

[in] pstm

Type: LPSTREAM

The address of the stream.

Return value

Type: HRESULT

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

Remarks

You should not create an image list that is written with the ILP_DOWNLEVEL flag with ILC_COLOR32.

To use ImageList_WriteEx, the application must specify Comctl32.dll version 6 in the manifest. For more information on manifests, see Enabling Visual Styles.

Requirements

Requirement Value
Minimum supported client Windows Vista [desktop apps only]
Minimum supported server Windows Server 2003 [desktop apps only]
Target Platform Windows
Header commctrl.h
Library Comctl32.lib
DLL Comctl32.dll (version 6.0 or later)

See also

ImageList_Read

ImageList_ReadEx

ImageList_Write

Reference