I'm trying to create an array with a size I don't know.
For instance:
Dim values() As Integer
Dim valuesString As String = ""
while something
valuesString = valuesString & newValue 7 ", "
end while
....trim off last ", "...
values = new integer() {valuesString}
However, in attempting to put the valuesString into the array, I get this
error:
System.FormatException: Input string was not in a correct format.
So, it looks like I can't put a comma-delimited string in as the values for
an array. As such, how should I approach this?
I went ahead and made two WHILE loops...the first to simply count the number
of items I need, then dim the array with a specific size, then do another
while loop to populate each of the values. Is there a more elegant way?
-Darrel
--
================================================== ===============
Win prizes searching google:
http://www.blingo.com/friends?ref=hM...nTqhv-2GE1FNtA