FormDataSource.first Method [AX 2012]

Moves focus to the first record in the data source.

public int first()

Run On

Client

Return Value

Type: int
A non-zero value if focus is successfully moved to the first record.

This method is called when a user selects the first record in a form by pressing CTRL+HOME.

The first method can be overridden on a form data source. Right-click the Methods node under the data source, point to Override Method, and then click first.

The following example overrides the first method for the InventTransPostingFinancial data source on the InventTrans form and returns the last record in another data source that is used on the form.

int first() 
{ 
    return inventTrans_ds.first(); 
}

Community Additions

ADD
Show: