UiPath Windows based - write line item(0).toString

Hi,

in windows legacy I used to write line as item(0).toString and it worked.

How do I do it in windows based?

image

Thx and kind regards,
Vanja

HI @VanjaV

have you tried like this

row("Column name").tostring

Regards
Gokul

1 Like

@VanjaV

Instead of item you have to use row

image

It depends on what is there in forEach field

row(0).ToString will give you the first column value

cheers

1 Like

Hi,

In ForEachRow, we can use indexer or Item property as the following.

Regards,

1 Like

Hello @VanjaV

Hope you are trying to print each value in the datatable using a For each row in datatable activity.

Maybe in legacy the variable was item, that’s why you have used item(0).ToString (here 0 is the index of the column)

Here as per the screenshot, the variable is row, so you need to use row(0).ToString or row(“Columnname”).ToString

Thanks

1 Like

Thank you very much: @Gokul001 / @Anil_G / @Yoichi / @Rahul_Unnikrishnan

it is working both ways:

image

Kind Regards,
Vanja

2 Likes

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