How to convert DataTable to IEnumerable



I was just wondering. If DataTable is an object is there a way to use it in ForEach control flow as a sort of collection?
And if yes, how do I convert DataTable to such iterable object?

Many thanks,


Hello @Klim

You can use For Each Row Activity or For Each Activity changing TypeArgument property:



Hi Susana,
thanks for your response! yes, I know about For Each Row and it works with an object DataTable just fine. But I was wondering is there a chance to convert a DataTable into enumerable / iterator object? just a technical question.



Hi @Klim,

Take a look at this:



Thanks @Susana! appreciate your response! it was very helpful.