CValueSet:InsertAt
The InsertAt method adds a member to the CValueSet at the specified set index. THis is inserted before the current member at the specified index. Conversely, the Add method inserts at the current end of the set.
boolean = CValueSet:InsertAt( nIndex, number_value )
boolean = CValueSet:InsertAt( nIndex, integer_value )
boolean = CValueSet:InsertAt( nIndex, string_value )
boolean = CValueSet:InsertAt( nIndex, boolean_value )
Inserts the (key, value) pair at the specified set index, nIndex, before the pair at the current nIndex.
The following example creates a CValueSet S and adds members to it:
|
-- constructor, set to values of type "number" |
|
-- add a key and value at index 1 |
|
-- add a key and value at index 2 |
|
-- add a key and value at index 3 |
|
-- Result: Old N= 3 |
|
-- inserts the new key and value between "key_1" and "key_2" |
|
-- Result: New N= 4 |
CValueSet Class, Add, Set, RemoveAt, InsertAt, SetAt
Mira Pro x64 Script User's Guide, v.8.73 Copyright Ⓒ 2024
Mirametrics, Inc. All Rights Reserved.