1 out of 1 rated this helpful - Rate this topic

GetObjectType function

Applies to: desktop apps only

The GetObjectType retrieves the type of the specified object.

Syntax

DWORD GetObjectType(
  __in  HGDIOBJ h
);

Parameters

h [in]

A handle to the graphics object.

Return value

If the function succeeds, the return value identifies the object. This value can be one of the following.

ValueMeaning
OBJ_BITMAPBitmap
OBJ_BRUSHBrush
OBJ_COLORSPACEColor space
OBJ_DCDevice context
OBJ_ENHMETADCEnhanced metafile DC
OBJ_ENHMETAFILEEnhanced metafile
OBJ_EXTPENExtended pen
OBJ_FONTFont
OBJ_MEMDCMemory DC
OBJ_METAFILEMetafile
OBJ_METADCMetafile DC
OBJ_PALPalette
OBJ_PENPen
OBJ_REGIONRegion

 

If the function fails, the return value is zero.

Requirements

Minimum supported client

Windows 2000 Professional

Minimum supported server

Windows 2000 Server

Header

Wingdi.h (include Windows.h)

Library

Gdi32.lib

DLL

Gdi32.dll

See also

Device Contexts Overview
Device Context Functions
GetObject
SelectObject

 

 

Send comments about this topic to Microsoft

Build date: 3/7/2012

Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ