Read and Review Automation Anywhere Documentation

Automation 360

Close Contents

Contents

Open Contents

List package

  • Updated: 9/17/2020
    • Automation 360 v.x
    • Build
    • RPA Workspace

List package

The List package contains actions that enable you to perform various operations on a variable of the list data type.

Working with variables of list data type

A list is a collection of ordered values. The values can be of Boolean, number, or string data subtype. When initializing a list variable, you can select the Any data subtype in order to hold any of the three data subtypes. You can manually enter values by creating a new variable or selecting an existing one from the Variables menu, and then clicking Add.

Common uses of list variables include:
  • Sending an email to multiple recipients.
  • Searching multiple web addresses.

Actions in the List package

If you are using a List action in a Loop action, you must use the For each item in the list iterator.

The following actions are available in the List package:

Action Description
Add item Inserts an item into a list variable. You can choose to add the item at the end of the list or specify a position in the list.
  • Select the list variable in which to add an item from the List variable list.
  • Select the variable that contains the value to add from the Item to be added list.
    Note: The variable must be of the same sub-data type as the other list items.
  • Select the To end of list option to insert the item at the end of the list or select At list index to specify the index in the list where to insert the item.

    The list index starts from 0. The first item in the list is at position 0, the second item at 1, and so on. For example, to add an item at the fourth position in a list, enter 3 in the At list index field.

Assign Assigns the value of the source list to the destination list variable.
  • Select the source list variable from the drop-down list or create a new list variable.
  • Select a list variable or create one to hold the output.

Clear Clears all items from the selected list variable.
Get item Retrieves a value at the specified position in a list and stores the output to a variable.
  • Select the list variable from which you want to retrieve a value from the List variable list.
  • Specify the position in the list from where you want to retrieve the value in the Index number field. The list index starts from 0. The first item in the list is at position 0, the second item at 1, and so on.
  • Select a variable that you want to use to store the output from the Assign the output to variable list.
Join items Combines all the available values in a list variable and stores the output to a string variable. You can specify the delimiter you want to use as a separator in the output.
  • Select the list variable that you want to use from the List variable list.
  • Specify the delimiter you want to use to separate values in the output in the Delimiter field.
  • Select a variable that you want to use to store the output from the Assign the output to variable list.
Remove item Removes an item from a list and assigns the output to a variable.
  • Select the list variable from which you want to remove an item from the List variable list.
  • Specify the position in the list from where you want to remove the value in the Index number field. The list index starts from 0. The first item in the list is at position 0, the second item at 1, and so on.
  • Select a variable that you want to use to store the output from the Assign the output to variable list.
Set item Sets an item at the specific position in a list and stores the output in a variable.
  • Select the list variable in which you want to set a value from the List variable list.
  • Specify the position in the list where you want to set the item in the Index number field. The list index starts from 0. The first item in the list is at position 0, the second item at 1, and so on.
  • Select a variable that you want to use to store the output from the Assign the output to variable list.
Size Retrieves the number of items in a list and assigns the output to a number variable.
  • Select the list variable for which you want to retrieve the size from the List variable list.
  • Select a number variable that you want to use to store the output from the Assigns the number of items to variable list.
Send Feedback