Add datatable to list

i want to add datatable to list
i used Add to collection activity in which Type of Argument is Datatable and Item is datatable_name and collection is List_name
i am getting list count but there is no data in List.

You cannot get data directly as a table,
Since you are using list
to get first table you need to use
List(0) -> is the first data table
.rows -> gives you total rows in the table

i am getting tablename of list is null, i used for each in list and within foreach , I used lognessage -> list.tablename ,but i am gettig Null


You need to use ForeachRow Activity for datatable

Hope this helps


but for each row is used for datatable and list is of List Datatable


Yes, You have to use For each-> Did you check the the properties of For each Type Arguments?

Can you share your workflow, so that we can check


i checked ,type of argument is of Type Datatable

@Ananya1 If the list is of type List(Of System.Data.Datatable) then When using For Each Activity on the List, the Type Argument should be set to Datatable.

If it is already set then to get TableName of Each table, you would have to use item.TableName, to get the Row Count, you would have to use item.Rows.Count