Clarifications in Get Row Item

Hello,

Please refer the attached screenshot, here I read the excel file and stored as DT1 and trying to pull the row item by using Get row item, I have used DT1.Rows(0) as a data row and column index as 0, output stored as RowItem, I was expecting 1 as an output as per my excel data.
but I am getting this error, please suggest.

Get Row Item: StringConverter cannot convert from System.Double.

Thanks
Vasan.

Hi!

Could you please try this!

dt1.Rows.Item(0)

Regards,
NaNi

Hi NaNi,

Thanks for writing, I have changed the code but its a same error still.
Here is my input excel snap.
image

Regards,
Vasan.

Hi!

Instead of giving the column number can we try with column name?

In the above snap which row data you’re trying to fetch?

Regards,
NaNi

Hi,

Can you try as the following?

img20220207-9

OR

Changing RowItem type String to GenericValue (UiPath.Core.GenericValue) type will also work.

Regards,

Thanks NaNi,
I was trying to pull the first row of the column(0), i.e (“Name”)
I changed the output type to Generic it worked.
Thankyou.

Thanks Yoichi,

I changed the type to Generic, its working fine.

Regards,
Vasan.

1 Like

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