(Obsolete – System Library)
Description: Insert List Item. This subroutine inserts an element into a list (single dimension array) and returns the modified list.
Returns: List
Usage: Script
Format: \System\InsertListItem(Array [, Index, Value])
Parameters: Array { array } { required } { no default }
Any array variable.
Index { numeric } { optional } { no default }
An optional parameter that is any numeric expression for the index at which to insert a new element. If this value is invalid, the new element will be inserted at the end of the array.
Value { varies } { optional } { no default }
An optional parameter that is any expression for the value to assign to the new array element.
Comments: This subroutine has been superseded by the InsertArrayItem function and is maintained for backwards compatibility only.
This subroutine is a member of the System Library, and must therefore be prefaced by \System\, as shown in the "Format" section. If the application you are developing is a script application, the System variable must be declared in APPMOD.SRC and need not be prefaced by a backslash in the function call.
For any optional parameter that is to be set, all optional parameters preceding the desired one must be present, although they may be invalid.
Examples:
Data = System\InsertListItem(Data { Array to use },
Invalid { Insert at end },
32 { Value of element });
Names = System\InsertListItem(Names
{ Array to use });
The first statement inserts an element with a value of 32 at the end of array Data, while the second statement inserts an invalid element at the end of array Names.
See Also: