FieldX

Use this function to return the X coordinate of a variable field object.

Syntax

FieldX (Field, Section, Form, Group)

Parameter

Description

Field

Enter the name of a field. The default is the current field.

Section

Enter the name of the section that contains the field you specified. The default is the current section.

Form

Enter the name of a form that contains the section and/or field you specified. The default is the current form.

Group

Enter the name of the form group that contains the form, section, and/or field you specified. The default is the current group.

You can use this function and the FieldY function to get the X and Y coordinates of a field object. Coordinates are stored in FAP units — 2400 units per inch. This means that an object located at (2400, 2400) occurs one inch from the top and one inch from the left.

Example

Here are some examples:

(Assume the field named MyField is located at X coordinate 1250.)

Function

Result

Explanation

Return(FieldX( ))

1250

Returns the current field’s X coordinate.

Return(FieldX ("MyField"))

1250

Returns the field’s X coordinate if the field is located on the current section.

Return(FieldX("MyField", "IMG\2", ,"GRP"))

1250

Returns the X coordinate of MyField located on the second occurrence of IMG within the specified form set group.

See also