field_count

Returns the number of fields in the current window.

Available in:

Apps (win) Apps (char) Reportwriter RPC Standalone PL
X X      

Syntax

int field_count()

Example

Modifies the active field based on the number of fields in the window:
{
if (p.af == 0) p.af = field_count() - 1;
else p.af--;
}