A -> Z in listbox

  • Thread starter Thread starter ZippyV
  • Start date Start date
Z

ZippyV

Hello,
I would like to populate a listbox with values A to Z. What would be the
best and fastest way to do this?
I tried to use a for-loop but I don't know how I would change the current
char value to the next letter.
 
Hi Ken,

I use aways (with the dataset in samples)

For i as Integer = 0 to 26
Listbox1.Items.Add(Chr(i+65)
Next

And then I see it from you and then I think, "funny how things who are the
same can look so different".

Cor
 
* "Cor said:
I use aways (with the dataset in samples)

For i as Integer = 0 to 26
Listbox1.Items.Add(Chr(i+65)

This will give a compile error. And why do an addition in every
iteration?

;-)
 
This will give a compile error. And why do an addition in every
iteration?

;-)
Not as you add that last character you did send.

I only wrote this because that when I saw it, I thought, yes it can also in
that way and who would think in this kind of solutions what is better or
worse.

I got my answer,

Thank you

:-)))

Cor
 
Cor,

* "Cor said:
Not as you add that last character you did send.

I only wrote this because that when I saw it, I thought, yes it can also in
that way and who would think in this kind of solutions what is better or
worse.

LOL

:-)))
 
Hello,
I would like to populate a listbox with values A to Z. What would be the
best and fastest way to do this?
I tried to use a for-loop but I don't know how I would change the current
char value to the next letter.

Well you've seen a bunch of code, so I won't boar you with my own
implementation... But, I will ask why not just edit the list boxes
items collection at design time? It's only 26 entries after all :)
 
Back
Top