Array - Set

 

Declaration

<AMARRAY ACTIVITY="set" NAME="text" STARTINDEXZERO="YES"><SETTER INDEX="text" VALUE="text" /><SETTER INDEX="text" VALUE="text" /></AMARRAY>

Related Topics   

Description

Sets the value of one or more elements in an existing array.

Practical Usage

Changes the value(s) of existing indexes in an array. Can optionally add additional index/value pairs as well.

Parameters

General

Property

Type

Required

Default

Markup

Description

Array name

Text

Yes

(Empty)

NAME="Array_Name"

The name of the array to set. The array must be created on a previous step with use of the Create array activity. Click the arrow button to populate existing index/value pairs.

Start index with 0

Yes/No

No

No

STARTINDEXZERO="YES"

If set to YES, the index value will start with 0. If set to NO (default) the index value will start with 1.

Index

Number

Yes

(Empty)

INDEX="text"

The name of the index. New index/value pairs may be added by selecting Click here to add new row...

Value

Text

Yes

(Empty

VALUE="text"

The value that the index should be set to. As with all parameters, this value may be literal or an expression (if surrounded by percent % signs). New index/value pairs may be added by selecting Click here to add new row...

 

Description

Error Causes

On Error

example

NOTE: The sample AML code below can be copied and pasted directly into the Steps panel of the Task Builder.

Description:

Create a double-dimensioned array of size 1 x 2 named "theArray".

<AMARRAY ACTIVITY="set" NAME="text" STARTINDEXZERO="YES"><SETTER INDEX="sampleIndex1" VALUE="text1" /><SETTER INDEX="sampleIndex2" VALUE="text2" /></AMARRAY>