PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK

  • Initial position (control and window)
  • Position of Tab control
  • Position of a control associated with a Tab control
  • Hidden button
  • Position of anchored control
  • Toolbar
  • Looper elements
  • Limits for the windows and window controls
  • Limits in the reports
  • Limits in the pages
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
..X is used to:
  • Find out the X coordinate of a control, of a Table control column or of a window (position on X axis).
    WEBDEV - Server codeWEBDEV - Browser codePHP This property is used to find out the X coordinate of a control in a page.
  • Modify the X coordinate of a control or window (position on X axis).
    WEBDEV - Server codeWEBDEV - Browser codePHP This property is used to modify the X coordinate of a stackable control in a page.
This property can be used on the controls found in a window, in a page, in a report, or on a window.
Versions 15 and later
Android This property is now available for Android applications.
New in version 15
Android This property is now available for Android applications.
Android This property is now available for Android applications.
Versions 17 and later
iPhone/iPad This property is now available for iPhone/iPad applications.
New in version 17
iPhone/iPad This property is now available for iPhone/iPad applications.
iPhone/iPad This property is now available for iPhone/iPad applications.
Versions 18 and later
Universal Windows 10 App This property is now available in Windows Store apps mode.
iPhone/iPad This property is now available for report controls in iPhone/iPad applications.
New in version 18
Universal Windows 10 App This property is now available in Windows Store apps mode.
iPhone/iPad This property is now available for report controls in iPhone/iPad applications.
Universal Windows 10 App This property is now available in Windows Store apps mode.
iPhone/iPad This property is now available for report controls in iPhone/iPad applications.
Versions 20 and later
AndroidiPhone/iPad This property is now available for Table controls in Android and iPhone/iPad applications.
New in version 20
AndroidiPhone/iPad This property is now available for Table controls in Android and iPhone/iPad applications.
AndroidiPhone/iPad This property is now available for Table controls in Android and iPhone/iPad applications.
Versions 21 and later
Universal Windows 10 App This property is now available in Universal Windows 10 App mode.
Apple Watch This property is now available in Apple Watch mode.
New in version 21
Universal Windows 10 App This property is now available in Universal Windows 10 App mode.
Apple Watch This property is now available in Apple Watch mode.
Universal Windows 10 App This property is now available in Universal Windows 10 App mode.
Apple Watch This property is now available in Apple Watch mode.
Example
// Find out the X coordinate of "IMG_Image" control
ResX = IMG_Image..X
Syntax

Finding out the X coordinate of an element Hide the details

<Result> = <Element used>..X
<Result>: Integer
  • X coordinate of specified element:
    • If the control belongs to a window, this X coordinate is expressed in pixels. It corresponds to the horizontal position of the upper-left corner of the control relative to the upper-left corner of the window's client area (i.e. the window without title bar, menu bar or borders).
    • If the control belongs to a report, this X coordinate is expressed in millimeters. It corresponds to the horizontal position of top left corner of element in relation to the top left corner of te block to which the control belongs.
    • If the control belongs to a page, this X coordinate is expressed in pixels. It corresponds to:
      • WEBDEV - Server code the horizontal position of top left corner of control in relation to the top left corner of the page. If the control belongs to a container control (HTML cell, looper, ...), the X coordinate is given in relation to this container control.
      • WEBDEV - Browser codePHP the horizontal position of top left corner of control in relation to the top left corner of the page.
  • X coordinate of specified column in a Table control (in pixels). Horizontal position of top left corner of column in relation to the top left corner of Table control.
  • WINDEVWINDEV Mobile X coordinate of window (in pixels). Horizontal position of top left corner of window in relation to the top left corner of the screen.
    Linux The X coordinate of window is not available.
<Element used>: Character string (with or without quotes)
Name of element whose X coordinate is requested.
For a control associated with a tab, use the following notation:
<Tab name>.<Control name>

Modifying the X coordinate of an element Hide the details

<Element used>..X = <New X coordinate>
<Element used>: Character string (with or without quotes)
Name of element whose X coordinate will be modified.
For a control associated with a tab, use the following notation:
<Tab name>.<Control name>
WEBDEV - Server codeWEBDEV - Browser code To modify the X coordinate of a page control, this control must be a stackable control.
<New X coordinate>: Integer
  • New X coordinate of the specified control:
    • If the control belongs to a window, this X coordinate is expressed in pixels. It corresponds to the horizontal position of the upper-left corner of the control relative to the upper-left corner of the window's client area (i.e. the window without title bar, menu bar or borders).
    • If the control belongs to a report, this X coordinate is expressed in millimeters. It corresponds to the horizontal position of top left corner of element in relation to the top left corner of te block to which the control belongs.
    • If the control belongs to a page, this X coordinate is expressed in pixels.
      • WEBDEV - Server code the horizontal position of top left corner of control in relation to the top left corner of the page. If the control belongs to a container control (HTML cell, looper, ...), the X coordinate is given in relation to this container control.
      • WEBDEV - Browser codePHP the horizontal position of top left corner of control in relation to the top left corner of the page.
      Remark: The control must be a stackable control otherwise the modification of the X coordinate will be ignored.
  • New X coordinate of specified column in a Table control (in pixels). Horizontal position of top left corner of column in relation to the top left corner of Table control.
  • WINDEVWINDEV Mobile New X coordinate for the specified window (in pixels). Horizontal position of top left corner of window in relation to the top left corner of the screen.
    Linux The X coordinate of the window cannot be modified.
Remarks
WINDEVAndroidiPhone/iPadApple WatchUniversal Windows 10 AppWindows MobileJavaUser code (UMC)

Initial position (control and window)

The initial position (defined in the "Details" tab of object description in the window editor) is returned by ..XInitial and ..YInitial. This position corresponds to the object position when opening the window and it can be modified by programming with ..X and ..Y.
WINDEVWindows MobileJavaUser code (UMC)

Position of Tab control

..X is used to find out and modify the horizontal position (in pixels) of the Tab control, relative to the upper-left corner of the window's client area (i.e. the window without title bar, menu bar or borders).
Important: If the coordinates of Tab control are modified by ..X, all the controls positioned on the tab will also be moved.
WINDEVWindows MobileJavaUser code (UMC)

Position of a control associated with a Tab control

If a control is associated with a pane of a Tab control, its coordinates are not relative to the Tab control but to the window's client area (i.e. the window without title bar, menu bar or borders).
If, after a modification, the coordinates of a control positioned on a Tab control no longer belong to the coordinates of this Tab control, the control is not displayed anymore.
WINDEVAndroidiPhone/iPadApple WatchUniversal Windows 10 AppWindows MobileJavaUser code (UMC)

Hidden button

You have the ability to use a "hidden" button by specifying negative coordinates (with ..X and ..Y). These negative coordinates can be used to define specific shortcuts for example. A specific process can be called from a button with negative coordinates so that it is not displayed in the window.
WINDEVAndroidiPhone/iPadApple WatchUniversal Windows 10 AppWindows MobileJavaUser code (UMC)

Position of anchored control

If a control is anchored, ..X is used to temporarily modify its X coordinate (until the next modification of the window size).
To permanently modify the position of an anchored control, use ..XInitial and ..YInitial.
WINDEVUser code (UMC)

Toolbar

..X can be used on a floating toolbar.
Versions 22 and later
WINDEViPhone/iPadUniversal Windows 10 AppUser code (UMC)

Looper elements

..X can be used on the elements found in a Looper control. In this case, ..X is used to find out the coordinates of the row inside the visible looper area.
If the element is not displayed in the visible looper area, ..X will return -4000.
Example:
LooperDisplay(LOOP_NoName1, 10)
ThreadPause(200)
Info("..X of elment 10: " + LOOP_NoName1[10]..X)
New in version 22
WINDEViPhone/iPadUniversal Windows 10 AppUser code (UMC)

Looper elements

..X can be used on the elements found in a Looper control. In this case, ..X is used to find out the coordinates of the row inside the visible looper area.
If the element is not displayed in the visible looper area, ..X will return -4000.
Example:
LooperDisplay(LOOP_NoName1, 10)
ThreadPause(200)
Info("..X of elment 10: " + LOOP_NoName1[10]..X)
WINDEViPhone/iPadUniversal Windows 10 AppUser code (UMC)

Looper elements

..X can be used on the elements found in a Looper control. In this case, ..X is used to find out the coordinates of the row inside the visible looper area.
If the element is not displayed in the visible looper area, ..X will return -4000.
Example:
LooperDisplay(LOOP_NoName1, 10)
ThreadPause(200)
Info("..X of elment 10: " + LOOP_NoName1[10]..X)
WINDEVAndroidiPhone/iPadWindows MobileJavaUser code (UMC)

Limits for the windows and window controls

WINDEVWindows Mobile ..X cannot be used on:
  • an option in a Check Box or Radio Button control,
  • a row in a List Box control, Combo Box control or Table control,
  • a group of controls,
  • a window menu,
  • an element in a TreeView control.
Java In Java, ..X only applies to the following elements:
  • Button.
  • Static.
  • Edit control.
  • Image.
  • Check Box.
  • Radio Button.
  • List Box.
  • Combo Box.
  • TreeView.
  • Tab.
  • Window.
  • Table.
  • Supercontrols.
AndroidiPhone/iPad ..X does not apply to the table columns.
WINDEVWEBDEV - Server codeReports and QueriesiPhone/iPadUniversal Windows 10 AppWindows Mobile

Limits in the reports

..X cannot be used on:
  • a report,
  • a report block.
Remark:
  • A control cannot be displayed outside the block to which it belongs.
  • ..Height and ..Width are used to find out the height and width of a report control or report block.
WEBDEV - Server codeWEBDEV - Browser codePHP

Limits in the pages

..X can only be used on the controls actually displayed in the browser. It cannot be used on:
  • an HTML table,
  • an option in a Check Box or Radio Button control,
  • a row in a List Box control, Combo Box control or Table control,
  • a cell in a Table control,
  • a group of controls.
Minimum version required
  • Version 9
This page is also available for…
Comments
Click [Add] to post a comment