How to use Array of string

Hi All:
I have a requirement as below:

  1. I want to put “a”, “b”, “c” to a Array of string D, the result is D={“a”, “b”, “c”}, I set the D=string, and used “assign” and loop to put the string, but I failed. So which activity should i use?

  2. I want to check if the D={“a”,“b”,“c"} includes the “a”, which function should I use?

Sorry for I’m new beginner, thanks very much in advance !

I found a tutorial for Dynamic list, but when I wanted to create the list, the error as below :tired_face:

Have solved “Not all …” error!

Select the list collection type in the dropdown list like string, integer,boolean

Array is a collection where the size is predefined.
If you want an array of three string elements you can use
arr = {"var1","var2","var3"}

You can assign values only to these three elements using Assign activity, like Assign arr(0) = "New Var"
which would make the array as {"New Var","var2","var3"}


On the other hand if you want to use a collection to keep adding elements to it, use List collection.
This thread might help you get a better understanding


You can do this -

simply using D.contains("a") within an If activity

Hope this helps :slight_smile: