Replace value Version 11 (Net)

Action group: Collections


Description

Replaces the value for the selected key in the dictionary

Action icon


Settings of parameters

PropertyDescriptionTypeFilling exampleMandatory field
Parameters
DictionaryDictionary for processing.Robin.Dictionary
Yes
KeyKey in the dictionaryRobin.String
Yes
New valueNew dictionary value by the specified keyRobin.Object
Yes

Special conditions of use

If nothing is specified in the "New value" parameter, the value of the key will change to empty.

If a non-existent key is specified in the "Key" parameter, an error will be caused.

Example of use 

Task

There is a variable "Dictionary" with values:

  1. Moscow
  2. Tokyo

It is necessary to change the value of key "1" to "Saint-Petersburg".

Solution

Use the "Replace value" action. 

Implementation

  1. Move the "Replace value" action to the workspace.


  2. Set the parameters of the "Replace value" action. 


  3. Click on the "Start" button in the top panel. 

Result

The value with the key "1" has been replaced by "Saint-Petersburg".

  • Нет меток