The OBJECT GET COORDINATES command returns the coordinates left, top, right and bottom (in points) in variables or fields of the object(s) of the current form defined by the parameters * and object.
If you pass the optional parameter *, it indicates that the object parameter is an object name (a string). If you don’t pass the optional parameter *, it indicates that object is a field or a variable. In this case, you don’t pass a string but a field or variable reference (only a field or variable of type object).
If you pass an object name to object and use the wildcard character (“@”) to select more than one object, the coordinates returned will be those of the rectangle formed by all the objects concerned.
Note: Since 4D version 6.5, it is possible to set the interpretation mode of the wildcard character (“@”), when it is included in a string of characters. This option has an impact on the “Object Properties” commands. Please refer to the 4D Design Reference manual.
If the object doesn’t exist or if the command is not called in a form, the coordinates (0;0;0;0) are returned.
Let’s assume that you want to obtain the coordinates of a rectangle formed by all the objects that begin with “button”:
OBJECT GET COORDINATES(*;"button@";vLeft;vTop;vRight;vBottom)