4D v14.3

OBJECT MOVE

Home

 
4D v14.3
OBJECT MOVE

OBJECT MOVE 


 

OBJECT MOVE ( {* ;} object ; moveH ; moveV {; resizeH {; resizeV {; *}}} ) 
Parameter Type   Description
Operator in If specified= object is an object name (string) If omitted = object is a variable
object  Form object in Object name (if * is specified) or Field or variable (if * is omitted)
moveH  Longint in Value of the horizontal move of the object (>0 = to the right, <0 = to the left)
moveV  Longint in Value of the vertical move of the object (>0 = to the bottom, <0 = to the top)
resizeH  Longint in Value of the horizontal resize of the object
resizeV  Longint in Value of the vertical resize of the object
Operator in If specified = absolute coordinates If omitted = relative coordinates

The OBJECT MOVE command allows you to move the object(s) in the current form, defined by the * and object parameters moveH pixels horizontally and moveV pixels vertically.

It is also possible (optionally) to resize the object(s) resizeH pixels horizontally and resizeV pixels vertically.

The direction to move and resize depend on the values passed to the moveH and moveV parameters:

  • If the value is positive, objects are moved and resized to the right and to the bottom, respectively.
  • If the value is negative, objects are moved and resized to the left and to the top, respectively.

If you pass the first optional parameter *, you indicate that the object parameter is a parameter name (a string of characters). If you don’t pass the * parameter, 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, all the objects concerned will be moved or resized.

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 Mode manual.

By default, the values moveH, moveV, resizeH and resizeV modify the coordinates of the object relative to its previous position. If you want the parameters to define the absolute parameters, pass the last optional parameter *.

This command works in the following contexts:

The following statement moves “button_1” 10 pixels to the right, 20 pixels to the top and resizes it to 30 pixels in width and 40 in height: 

 OBJECT MOVE(*;"button_1";10;-20;30;40)

The following statement moves “button_1” to the following coordinates (10;20) (30;40):

 OBJECT MOVE(*;"button_1";10;20;30;40;*)

 
PROPERTIES 

Product: 4D
Theme: Objects (Forms)
Number: 664

 
HISTORY 

Modified: 4D v6.7
Renamed: 4D v12

 
SEE ALSO 

OBJECT DUPLICATE
OBJECT GET COORDINATES
OBJECT SET COORDINATES

 
ARTICLE USAGE

4D Language Reference ( 4D v12.4)
4D Language Reference ( 4D v14 R3)
4D Language Reference ( 4D v14 R2)
4D Language Reference ( 4D v13.5)
4D Language Reference ( 4D v14.3)
4D Language Reference ( 4D v14 R4)

Inherited from : MOVE OBJECT ( 4D v11 SQL Release 6)