Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21876

Use of timers

$
0
0
I'm creating frustration in visual basic 6 and I have encountered a problem.

I'm trying to use timers to have the 'Roll Dice' button do a different thing every time. I need it to move the first players counter the firs time you press the button and when you press it again it should move the second players counter and so on for the third and fourth player. I'm using an array of text boxes for the position of the player and I have managed to get the first player moing but I can't seem to get the other three to move.

Any help would be appreciated.

Here is the code I am using:

Do Until toTal = 0
txtSquare(player1position).BackColor = vbWhite
player1position = player1position + 1
toTal = toTal - 1
If player1position > 39 Then player1position = 0
txtSquare(player1position).BackColor = vbRed
Loop

Viewing all articles
Browse latest Browse all 21876

Trending Articles