What does row("A").ToString means?

Hi I am trying to understand what does this means:

The Assign looks like this:

There is an excel sheet with column name A where they would be input some ID in its rows.

I am still learning UiPath, I am seeking some guidance, thank you in advance.

1 Like

@Irfan_Musa

row(“IMO”).tostring means the value in the column of IMO are assigning to that variable IMO

row(“A”).tostring means fetching the value which is present in column of A

Hi

I hope you have this inside a FOR EACH ROW loop
If that’s the case with this assign activity they are trying get the value of a column “IMO” from each row using row(“IMO”).ToString and assigning it to a variable IMO

To learn more about this
Have a view on this video tutorial

Cheers @Irfan_Musa

Hi @Irfan_Musa

Let’s assume this is your Excel data:

image

& let’s say you read the data & store the value in a data table variable ‘dt_excelData’.

Once you iterate through the data table row by row, each iteration goes through the data rows available, like this:

image

When the loop runs for the first time, the value of the row(“IMO”).ToString will be ‘1’ & the value of the row(“Name”).ToString will be ‘A’. This keeps on continuing till all the rows are processed.

Hope this helps,
Best Regards.

1 Like

Hello

row = the current row
(“IMO”) = the column name
.ToString = the format of the cell value

Take a look at this tutorial

When you get that understood, look into and refer to this post from the great @Palaniyappan
All about Datatable - UiPath - News / Tutorials - UiPath Community Forum

Hopefully this helps :blush:

Cheers

Steve

1 Like

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