Initializing Lists in Power Automate Desktop with data

--

Problem

In Power Automate desktop , if you want to Initialize a list then it is pretty easy. Just drag and drop the “Create new list” connector.

The above connector only initializes an empty list. If we want to add any values to the list then we need to use “Add items to list” connector and pass the value that needs to be added to the list.

Adding item “January” to List

This quickly becomes cumbersome if you need to add multiple items to the list and adding “Add item to list” for each and every item is not feasible.

Solution

To initialize a new list with data we can use the “Set variable” connector and initialize the the same as follows:

%[‘Jan’, ‘Feb’, ‘Mar’, ‘Apr’, ‘May’, ‘Jun’, ‘Jul’, ‘Aug’, ‘Sep’, ‘Oct’, ‘Nov’, ‘Dec’]%

Creating a new list variable with data

I hope you like this neat little trick :)

--

--

No responses yet