Re: How do I get a datatable as an array

H

Hermit Dave

well you dont need to have an array to iterate it.
you can get the count using DataTable.Rows.Count and you can iterate it to
populate your table.

but if you still want to array use DataTable.Select() to get the array of
type DataRow
 
A

ajaymehra

Hi,
I have a function in a module specified as an ICollection, whic
basically creates a datatable with 2 columns and fills some data in it
Now from my main program - I want to get this datatable as an array.
I need to use the values in the datatable and create a dynami
table in my application - which is why I dont want to databind...

Thanks in advance for the help..

aja

ajaymehr
 
A

ajaymehra

thanks Dave - your help is much appreciated.

Hermit said:
*well you dont need to have an array to iterate it.
you can get the count using DataTable.Rows.Count and you can iterat
it to
populate your table.

but if you still want to array use DataTable.Select() to get th
array of
type DataRow

ajaymehr
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,430
Messages
2,571,676
Members
48,796
Latest member
Greg L.

Latest Threads

Top