Is it possible to Read a dataRow from a DataTable based on row Index.
Please help me.
Is it possible to Read a dataRow from a DataTable based on row Index.
Please help me.
Hello @maria.josephina Yes it is possible to read. You can go through this to get better understanding
https://activities.uipath.com/docs/get-row-item
Also, you can get Row index from datatable inside Loop like below :
foreach(DataRow row in yourdatatable.Rows)
{
Int value_row_index =yourdatatable.Rows.Indexof(row)
//Writeline value_row_index.ToString()
}
If my DataTable ‘dataTable’ consists of 10 elements(data) and if I want to retrieve 1st element, What query can I use.
something like : dataTable.Rows(0)
Hi - can you try using the following expression : datatable.row.index(value)
DataTable.Rows(0)(0).ToString
DataTableVariable.Rows(RowIndex)(ColIndex).ToString
This would give you first element which is at First Row First Column
Thanks,
Prankur
yes you can: DataTableName.Rows(row_Index).item(Col-Index/col_Name).ToString
Mark it as solution if it worked
Thanks,
Prankur
Hi Pankur how can obtain a range of values in a datatable… Example i have only a column and I need the row number 0 to the row number 14.