There is a dataset that has 1000 rows.
i can use only 5 threads that has to process all 1000 rows. Need a method for this passing datatable as parameter to the method and iterating through the rows.
For instance,
If the first 5rows are processed by the first 5 threads initially,
Then when any one of those 5 thread completes the process the thread is free, it has to process the next available data row in the data table. and this has to continue til 1000 rows are complete.. but ONLY using 5 threads

Sam HobbsRank #108 · 20.5K reputationPosted Feb 22, 2011, 4:28 PM EST
Prabhu Chandramouleesw5 reputationPosted Feb 23, 2011, 7:52 AM EST
Suthish NairRank #92 · 22.8K reputationPosted Feb 23, 2011, 8:50 AM EST
Can you explain what you want to do with this kind of logic?
Prabhu Chandramouleesw5 reputationPosted Feb 23, 2011, 9:03 AM EST
i have a datatable that has 1000 rows. i can use only 5 threads that has to process all 1000 rows. Need a method for this passing (datatable dt)as parameter to the method and iterating through the rows therby processing every cells in the datarow being processed. For instance, If the first 5rows are processed by the first 5 threads initially, Then when any one of those 5 thread completes the process the thread is free, it has to process the next available data row in the data table. and this has to continue til 1000 rows are complete.. but ONLY using 5 threads
Would be of great help
Sam HobbsRank #108 · 20.5K reputationPosted Feb 23, 2011, 10:37 AM EST