共用方式為


GetRegionData

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

This function fills the specified buffer with data describing a region. This data includes the dimensions of the rectangles that make up the region.

Syntax

DWORD GetRegionData(
  HRGN hRgn, 
  DWORD dwCount, 
  LPRGNDATA lpRgnData
); 

Parameters

  • hRgn
    [in] Handle to the region.
  • dwCount
    [in] Specifies the size, in bytes, of the lpRgnData buffer.
  • lpRgnData
    [out] Long pointer to a RGNDATA structure that receives the information.

    If this parameter is NULL, the return value contains the number of bytes needed for the region data.

Return Value

This function returns the number of bytes required for the region data in lpRgnData. If the return value is less than or equal to the value in dwCount, the function is successful.

Zero indicates failure, such as when the handle in hRgn is invalid.

To get extended error information, call GetLastError.

Remarks

A Windows Embedded CE implementation of GetRegionData may return more rectangles for a specified region than a Windows-based desktop platform implementation.

Requirements

Header windows.h
Library coredll.lib
Windows Embedded CE Windows CE 1.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Reference

RGNDATA
GDI Functions