Hi I have a datatable with lakhs of rows into it . now i want to Spit the datatable into chunks of 30000 and add it to the excel file .. How can i acheive this
Hi @vishal_nachankar
Please look into the following thread:
Hey guys,
So i generate a datatable with 100+ rows every week. Now i’d like to split that table into 4 parts with about equal numbers of rows in each. Found some rather complicated solutions but is there a simple way to do this?
And also a random question: What would be the best language to learn to improve in UIpath? C#?
Thanks,
Best Regards.
Yoichi
(Yoichi)
27.Апрель.2023 09:50:14
4
Hi,
Hope the following sample helps you.
arrDt = Enumerable.Range(0,(dt.Rows.Count \ chunkSize)-CInt(dt.Rows.Count mod chunkSize >0)).Select(Function(i) dt.AsEnumerable.Skip(i*chunkSize).Take(ChunkSize).CopyToDataTable).ToArray
Sample20230427-5L.zip (8.6 KB)
Regards,