Set Array Element Operator []
Set the value of an array element.
Syntax  | 
  | |
|---|---|---|
Semantics  | The operator  The first element has the position 0. 
  | |
Substitutables  | 
  | Can be any variable or object attribute having the type Array.  | 
  | Can be any expression that evaluates to an integer.  | |
| 
    
 It is not possible to use class operations as index function – only built-in action script language operations are allowed.  | ||
Examples  | Set a specific array element Input: an array of names 
        JSON
     
    
        CODE
     
    
Result: 
        JSON
     
    
 | |
Set the last array element Input: an array of names 
        JSON
     
    
        CODE
     
    
Result: 
        JSON
     
    
 | ||
Set a property from a complex array element Input: a list of articles 
        JSON
     
    
        CODE
     
    
Result: 
        JSON
     
    
 | ||
Related Content
Related Pages:
Get Array Element Operator []
Returns an array element.