INFO: Using Screen Coordinates with Multiple Display Monitors (229682)



The information in this article applies to:

  • Microsoft Win32 Application Programming Interface (API), when used with:
    • the operating system: Microsoft Windows 2000
  • Microsoft Windows XP Professional
  • the operating system: Microsoft Windows XP 64-Bit Edition

This article was previously published under Q229682
This article discusses a Beta release of a Microsoft product. The information in this article is provided as-is and is subject to change without notice.

No formal product support is available from Microsoft for this Beta product. For information about how to obtain support for a Beta release, see the documentation that is included with the Beta product files, or check the Web location from which you downloaded the release.

SUMMARY

In Windows 98 and Windows 2000, negative screen coordinates should not be used to hide a window. Negative screen coordinates as well as coordinates beyond the dimensions of the primary monitor may be in the range of the display area on a multiple monitor system.

MORE INFORMATION

The Multiple Display Monitors feature allows applications to make use of multiple display devices at the same time. The user determines the arrangement of the monitors on the virtual screen. For Windows 2000, the primary monitor can be any monitor. When the primary monitor is not in the upper-left corner of the virtual screen, parts of the virtual screen have negative coordinates.

For this reason, do not use negative coordinates or coordinates larger than the width and height of the primary display monitor to hide a window, or to keep a window visible. Windows that are assigned screen coordinates above or below these limits may appear on another monitor.

You should not prevent windows from displaying at negative coordinates, or your application will not be able to make proper use of multiple monitors.

NOTE: Use the GET_X_LPARAM and GET_Y_LPARAM Windows macros to retrieve the signed coordinates that are packed in the LPARAM value.

Modification Type:MinorLast Reviewed:5/10/2006
Keywords:kbDSWGDI2003Swept kbFAQ kbinfo KB229682