MONITORINFOEX

 

Description

 

The MONITORINFOEX structure contains information about a display monitor.

 

The GetMonitorInfo function stores information into a MONITORINFOEX structure or a MONITORINFO structure.

 

The MONITORINFOEX structure is a superset of the MONITORINFO structure. The MONITORINFOEX structure adds a string member to contain a name for the display monitor.

 

C++ Syntax

 

typedef struct tagMONITORINFOEX {

DWORD cbSize;

RECT  rcMonitor;

RECT  rcWork;

DWORD dwFlags;

TCHAR szDevice[CCHDEVICENAME];

} MONITORINFOEX,

*LPMONITORINFOEX;

 

PowerBASIC Syntax

 

TYPE MONITORINFOEX

cbSize    AS DWORD

rcMonitor AS RECT

rcWork    AS RECT

dwFlags   AS DWORD

szDevice  AS ASCIIZ * %CCHDEVICENAME

END TYPE

 

Unicode version:

 

TYPE MONITORINFOEXW

cbSize    AS DWORD

rcMonitor AS RECT

rcWork    AS RECT

dwFlags   AS DWORD

szDevice  AS STRING * %CCHDEVICENAME * 2

END TYPE

 

Members

 

cbSize

 

The size of the structure, in bytes.

 

Set the cbSize member to SIZEOF ( MONITORINFOEX ) before calling the GetMonitorInfo function. Doing so lets the function determine the type of structure you are passing to it.

 

rcMonitor

 

A RECT structure that specifies the display monitor rectangle, expressed in virtual-screen coordinates. Note that if the monitor is not the primary display monitor, some of the rectangle's coordinates may be negative values.

 

rcWork

 

A RECT structure that specifies the work area rectangle of the display monitor, expressed in virtual-screen coordinates. Note that if the monitor is not the primary display monitor, some of the rectangle's coordinates may be negative values.

 

dwFlags

 

A set of flags that represent attributes of the display monitor.

 

The following flag is defined.

 

Value

Meaning

MONITORINFOF_PRIMARY

This is the primary display monitor.

 

szDevice

 

A string that specifies the device name of the monitor being used. Most applications have no use for a display monitor name, and so can save some bytes by using a MONITORINFO structure.

 

Valid XHTML 1.0 Transitional