Hi everyone,
I have a "SqlDataReader" that I know has 2 columns in it with around
361 rows of data like:
columnA columnB
value1 value3
value1 value4
I am trying to read this into a rectangular string array called
myArray()(). The problem is I don't know how!!
Can anyone help me please? Any suggestions/comments/ideas/code-samples
greatly welcomed.
Thank you,
Al.
I Don't Like Spam - 14 Dec 2005 14:50 GMT
> Hi everyone,
>
[quoted text clipped - 14 lines]
> Thank you,
> Al.
Why not use a DataTable. It is basically the same array. There are a
thousand examples about this if you do a google search.
But for what you asked:
Pseudo code:
Do while MyDataReader.Read
MyStringArray(RowCount)(0) = MyDataReader.GetString(0)
MyStringArray(RowCount)(1) = MyDataReader.GetString(1)
Loop
Chris