Partager via


GetIconInfo

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

This function retrieves information about the specified icon or cursor.

Syntax

BOOL GetIconInfo(
   HICON hIcon,
   PICONINFO piconinfo
);

Parameters

  • hIcon
    [in] Handle to the icon or cursor. To retrieve information about a standard icon or cursor, specify one of the following values.

    Value Description

    IDC_APPSTARTING

    Standard arrow and small hourglass cursor.

    IDC_ARROW

    Standard arrow cursor.

    IDC_CROSS

    Crosshair cursor.

    IDC_HAND

    Hand cursor.

    IDC_HELP

    Arrow and question mark cursor.

    IDC_IBEAM

    I-beam cursor.

    IDC_NO

    Slashed circle cursor.

    IDC_SIZEALL

    Four-pointed arrow cursor pointing north, south, east, and west.

    IDC_SIZENESW

    Double-pointed arrow cursor pointing northeast and southwest.

    IDC_SIZENS

    Double-pointed arrow cursor pointing north and south.

    IDC_SIZENWSE

    Double-pointed arrow cursor pointing northwest and southeast.

    IDC_SIZEWE

    Double-pointed arrow cursor pointing west and east.

    IDC_UPARROW

    Vertical arrow cursor.

    IDC_WAIT

    Hourglass cursor.

    IDI_APPLICATION

    Application icon.

    IDI_ASTERISK

    Asterisk icon.

    IDI_EXCLAMATION

    Exclamation point icon.

    IDI_HAND

    Stop sign icon.

    IDI_QUESTION

    Question-mark icon.

    IDI_WINLOGO

    Windows logo icon.

  • piconinfo
    [out] Pointer to an ICONINFO structure. The function fills in the structure's members.

Return Value

If the function succeeds, the return value is nonzero and the function fills in the members of the specified ICONINFO structure.

If the function fails, the return value is zero. To get extended error information, call GetLastError.

Remarks

The ICONINFO structure contains two bitmaps: hbmMask and hbmColor. These bitmaps are managed by the operating system and should not be released or deleted by the application.

Requirements

Header winuser.h
Library Icon.lib
Windows Embedded CE Windows CE 5.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Reference

Resources Functions