Using for loop variables in a trim whitespace function

Hi

How to I use the variables from my for loop (element1 in element2) for example in my trim whitespace function

It is not showing in the drop down menu, the item option in 1.1.9 still gave the you option in the drop down menu?

Hi Gerhard,
The element when applied to table returns a list ( as shown below), so you need to use one more loop to be able to use Trim Whitespace (it can only be applied to a string variable)

There have been several questions about the context variables lately.
Do you think the logic is now more complicated than earlier and we should create a guide on using element and similar variables in Loops, If-Else, etc.?

Thank you.

I always find any info very helpful as you might still learn something you did not know, so I would really find it useful

1 Like

I see in the drop down menu I cannot save to element again?

see below (ouput section). I need to define element as an variable first, previously you did not have to

In the for each loop description, https://kb.workfusion.com/display/RPAe/Loops#Loops-ForEach
perhaps this part can also be added as an example to clearly show that to get each element of the table you need to have another sub loop. From the current description it’s not very clearly understood. A number of people had that confusion about the first loop returning a list

1 Like

Yes, thank you, good idea. Will update the knowledge base.