indexOf

Syntax indexOf (value)

Params value is an object whose index you wish to determine.

Action Determines the index number of the specified object.

Returns The index number.

Examples indexOf (scratchpad)

   » 2

indexOf (config.mainResponder)

   » 1

indexOf (non.existent.object) //non-existent object

   » 0

local (x);new (tableType, @x);x.a = "Foo";x.b="Bar";indexOf (x.b) //local table

   » 2

Notes The index of an object is dependent on the current sort order of the table it's in. The default sort order of a table is by name.

You can get the index of objects in local tables.

If the object doesn't exist, its index is 0.

This verb is new in Frontier 6.1.

See Also nameOf

parentOf

typeOf

sizeOf

Discuss