How to access row Item from specific column?

If currentRow represents a row from a DataTable with two column in this order: Name and Age, what expression can be used to obtain the value from the column Age?

1 Like

currentRow.item(0).toString and currentRow.item(1).toString

1 Like

Hello @lordsupremo

You can use this

age = dt.Rows(0)(“age”).ToString

1 Like

Is this the training exam question :thinking:

Hi @lordsupremo,

you can use 2 ways.

currentRow .Item(1).ToString()
or
currentRow .Item(“Age”).ToString()

Regards
Balamurugan.S

currentRow(“Age”)