"Cor Ligthert" <no************@planet.nl> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
Mythran,
I did want to show it in its shortest way without the array. However when
I did not showed the array than it would (be when there was not
databinding in the sample) imposible to get the or set the values.
Therefore I added it at the last moment and was to lazy to do it real in
the best way.
However
Dim textBoxes(9) As TextBox
For x As Integer = 0 To textBoxes.count -1
textBoxes(x) = New TextBox()
textBoxes(x).Top = y
controls.Add(textBoxes(x))
Next
The name is in my opinion not real needed when it is in an array.
:-)
Cor
Cor,
I was simply showing a shorter way, using your example as a base, and
throwing in some sarcastism about myself :P Wasn't meant to be taken that
your way was too long, just showing that it "can" be shortened...I didn't
want to be too anal retentive and do it all on one line, but at the same
time, rid it of some unnecessary additional code just for kicks. Either way
will work, and I have written code often enough using a variable that really
wasn't necessary for all practical purposes :)
But in any sense, sorry that I didn't make myself clear enough about why I
posted the shorter version. It wasn't to tickle anybody's fancy (darn),
just to broaden the minds of others....like that ever happens with my
posts...
Mythran