Hangman Game need help

Status
Not open for further replies.

VBChallenged

Solid State Member
Messages
6
right now i'm having trouble loading my alphabet by using a control array. i was given this code to use and it still isn't working right. If anyone could help me find where the problem is i would greatly appreciate it.

for i = 1 to 25
load lblAlphabet(i)
lblAlphabet(i).left = lblAlphabet(i).left + i * conLeftC
lblAlphabet(i).caption = Mid(strAlpha, i + 1, 1)
lblAlphabet(i).visible = true
next i

(conLeftC = 270 in your general decleration)
(strAlpha = "abcdefghijklmnopqrstuvwxyz" in general declaration)
 
How is it not working? If it's not loading anything at all, do you have lblAlphabet(0) loaded at design time?
 
The labels wern't spacing out right and were just being placed underneath one another. I added...

lblAlphabet(i).left = lblAlphabet(i).left + lblAlphabet(i).left
to my code and now it works fine.

Thank you for you reply though.
 
i made a hangman game.

that was one of the first things that i ever did. it really teaches you a lot about some of the commands and how they work :p
 
Status
Not open for further replies.
Back
Top Bottom