XenoGuard 4.0 Documentation

Add

ActionStep Reference » Programming » Dictionary » Add 

The ActionStep Dictionary Add assigns a key-value pair to the dictionary and stores the values in the Key and Value of the result list.


[-] Hide
  1. Open the Programming node in the Workspace Explorer.
  2. In the Dictionary node, select the Add ActionStep.

Parameters:

The ActionStep has the following input parameters:


name Description
Dictionary
The collection of key-value pairs.

Allowed Context Scopes
 [Local, Global]
Key The key of the dictionary.

Allowed Context Scopes [Local, Global]
Allowed Context Types [Variable, Parameter, Enum]
Value
The value of the dictionary.

Allowed Context Scopes
[Fixed, Local, Global]
Allowed Context Types [Variable, Parameter, Enum]
Ignore Error Determines whether an existing key is not handled as an error

Allowed Value [Boolean]

Results:

The ActionStep returns the following results:


name
description
Key Contains the added key to the dictionary.

Allowed Context Scopes [Fixed, Local, Global]
Allowed Context Types [Variable, Parameter]
Value Contains the added value to the dictionary.

Allowed Context Scopes [Fixed, Local, Global]
Allowed Context Types [Variable, Parameter]

Warning An exception occurs when the Key value is not unique or has a duplicate. However, the error is handled by XenoGuard when the Ignore Error parameter was set as "True".

Example 1 (Insert content to a created dictionary):

This example adds key-value pairs to the created local DNS Names dictionary. The result of each key-value pair in Key is then output via Write Text.

See other Dictionary operations:

Create
Get
Get At
Count
Contains
Iterate
Remove
Remove At
Clear