Why is object type coming out of a List<String> variable?

From the list variable with string as elements, if I run for each, an object type comes up and I need to cast into string type by making item.ToString, but I don’t why should I covert the type when taking a string type value is extracted. Can anyone explain to me about it? Thank you!

Daniel

1 Like

Hi @Daun

Have you set for each item type as string instead of list(of string)

Thanks
Ashwin S

2 Likes

Fantastic
Inside the for each loop we can use read range
But
The read must be used only within a EXCEL APPLICATION SCOPE or we can use READ RANGE from WORKBOOK ACTIVITIES
That’s why this error comes up
Make sure that the for each activity has type argument property as string in its property panel

So use a excel application scope and then use a read range within for each or use workbook activities read range and it would work for sure
You were almost done

And for this

This we need to mention the type argument of for each loop to let know the loop in what type of argument I.e., what datatype of value to be used and passed inside the loop

Hope this would help you
Cheers @Daun

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.