Export (0) Print
Expand All

GetClassInfo function

Retrieves information about a window class.

Note  The GetClassInfo function has been superseded by the GetClassInfoEx function. You can still use GetClassInfo, however, if you do not need information about the class small icon.

Syntax


BOOL WINAPI GetClassInfo(
  _In_opt_  HINSTANCE hInstance,
  _In_      LPCTSTR lpClassName,
  _Out_     LPWNDCLASS lpWndClass
);

Parameters

hInstance [in, optional]

Type: HINSTANCE

A handle to the instance of the application that created the class. To retrieve information about classes defined by the system (such as buttons or list boxes), set this parameter to NULL.

lpClassName [in]

Type: LPCTSTR

The class name. The name must be that of a preregistered class or a class registered by a previous call to the RegisterClass or RegisterClassEx function.

Alternatively, this parameter can be an atom. If so, it must be a class atom created by a previous call to RegisterClass or RegisterClassEx. The atom must be in the low-order word of lpClassName; the high-order word must be zero.

lpWndClass [out]

Type: LPWNDCLASS

A pointer to a WNDCLASS structure that receives the information about the class.

Return value

Type:

Type: BOOL

If the function finds a matching class and successfully copies the data, the return value is nonzero.

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

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Winuser.h (include Windows.h)

Library

User32.lib

DLL

User32.dll

Unicode and ANSI names

GetClassInfoW (Unicode) and GetClassInfoA (ANSI)

See also

Reference
GetClassInfoEx
GetClassLong
GetClassName
RegisterClass
RegisterClassEx
WNDCLASS
Conceptual
Window Classes

 

 

Community Additions

ADD
Show:
© 2014 Microsoft