Name
GetItem -- get list item (V9.0)
Synopsis
item = GetItem(list, idx)
Function
This returns the item at index idx in the list specified by list. If idx is -1, the last list item will be returned. If idx is out of range, Nil will be returned.

Note that you normally shouldn't use this function because you can access list elements quicker by just using the []-operator. The only case where using this function has a real speed advantage is when you want to get the last item of an optimized list and you don't know the number of items in the list. In that case, using GetItem() is faster than calling ListItems() first.

Inputs
list
list to use
idx
index of the list item to get; pass -1 to get the last item
Results
item
item at the specified index

Show TOC