For

From the documentation:

[quote]Counting backward
To count from 5 down to 1, you can write:

For loopIndex As Integer = 5 DownTo 1

Or:

For loopIndex As Integer = 1 To 5 Step -1

[/quote]

Is the second example supposed to work?

[quote=150805:@Thomas White]From the documentation:

Is the second example supposed to work?[/quote]

It works. I never use downto but step -. Old habits are hard to break…

It doesn’t do anything for me :frowning:

They shouldn’t have flipped the 1 and 5. Should be like this to loop a few times

For loopIndex As Integer = 5 To 1 Step -1

I’ve fixed the 2nd example.