Home | Sign in | English EN
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WindowsLinuxPHPWEBDEV - Browser code
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Stored procedures
Returns the coordinates of the screen that contains a window. Then, you have the ability to manage the positions or the sizes of windows in a single-screen or multi-screen environment. You can for example find out whether a window exceeds the size of the screen or whether the window is centered in the screen.
sRect is string = WinScreenRectangle(WIN_Window1, screenWithoutTaskbar)
nYMax is int = ExtractString(sRect, 4)
<Result> = WinScreenRectangle([<Window name> [, <Options>]])
<Result>: Character string
Dimensions of the screen where the window is displayed. These coordinates are returned in the following format:
<X1> + TAB + <Y1> + TAB + <X2> + TAB + <Y2>
  • The (X1, Y1) coordinates correspond to the top left corner of the screen.
  • The (X2, Y2) coordinates correspond to the bottom right corner of the screen.
If 2 screens are used and if the window is displayed on the second screen, the (X1, Y1) coordinates correspond to the coordinates of the second screen (1280, 0 for example).
<Window name>: Optional character string (with or without quotes)
Name or alias of window to use.
If this parameter is not specified or if it corresponds to an empty string (""), the calling window is used.
The main screen is used if no window is opened.
<Options>: Optional integer constant
Elements taken into account for the size of the screen:
screenWithoutTaskbarIf the taskbar is active on the screen, its size is subtracted.
(Default value)
Total size of the screen.
Component: wd260obj.dll
Minimum version required
  • Version 12
This page is also available for…
Click [Add] to post a comment