IndexedElementOfList

Typeoperator
DictionaryLCB
LibraryLiveCode Builder
Syntax
<Target> [ <Index> ]
Associationscom.livecode.list
Summary

Designates the element at index Index in Target. Synonym:SingletonElementOf

Parameters
NameTypeDescription
Index

An expression which evaluates to a valid integer index of Target.

Target

An expression which evaluates to a list.

Example
variable tVar as List
put [1,2,3] into tVar
put "A" into tVar[1] -- tVar is ["A",2,3]

variable tNum as Number
put tVar[2] into tNum -- tNum is 2
Description

Either locates the element container at the given index for use as the target container of another operation, or evaluates the element at the given index as the source of another operation.

Note: It is an error if Index is out of range.

Tagslists