Reference > Functions reference > Get functions > Get(ActiveRecordNumber)
 

Get(ActiveRecordNumber)

Returns a number representing the record that has focus in the current found set.

Format 

Get ( ActiveRecordNumber )

Parameters 

None

Data type returned 

number

Originated in 

FileMaker Pro 17.0 Advanced

Description 

The value returned is the current record number displayed in the navigation controls in the status toolbar. It is determined by the relative place of the record in the found set, and it changes depending on the find criteria and the sort order.

Notes 

To return a value that uniquely and permanently identifies a record in this table, use the Get(RecordID) function.

Example 1 

Returns 4 when the fourth record in the found set has focus.

Example 2 

In a portal that shows records from the current table, suppose you want to display a button in a portal row only when the row is the active portal row. (This condition occurs when the record's position in the current found set is the same as the number of the record that has focus.)

To hide the button when the row is not the active portal row, select the button. In the Data Data tab of the Inspector, enter the following formula for Hide object when:

not ( Get ( RecordNumber ) = Get ( ActiveRecordNumber ) )

You can also apply this example to show a button only in the active record in List View.

See Creating portals for master-detail layouts and Hiding or showing layout objects.

Related topics 

Functions reference (category list)

Functions reference (alphabetical list)

About formulas

About functions

Defining calculation fields

Using operators in formulas

Get(RecordNumber) function