Share via


Gdi::DeleteObject_I (Windows Embedded CE 6.0)

1/6/2010

This method deletes a logical pen, brush, font, bitmap, region, or palette, freeing all system resources associated with the object. After Gdi::DeleteObject_I deletes the object, the specified handle is no longer valid.

Syntax

static WINGDIAPI BOOL WINAPI DeleteObject_I(
  HGDIOBJ hgdiobj
);

Parameters

  • hgdiobj
    [in] Handle to a logical pen, brush, font, bitmap, region, or palette.

Return Value

Nonzero indicates success.

Zero indicates that the specified handle is not valid or that the handle is currently selected into a device context.

To get extended error information, call GetLastError.

Remarks

This method is an internal version of the DeleteObject function.

Do not delete a drawing object, such as a pen or brush, while you still have the object selected into a device context.

When you delete a pattern brush, the bitmap associated with the brush is not deleted. You must delete the bitmap independently.

Requirements

Header gdi.hpp
Windows Embedded CE Windows CE .NET 4.0 and later

See Also

Reference

Gdi
DeleteObject
Gdi::SelectObject_I