I thought I finally had it down, but I have a picture loading problem. I have 3 Procedures: CheckX, CheckO, and ResetSquares.
In the frame properties I have:
- Code: Select all
sq1 = 0
sq2 = 0
sq3 = 0
sq4 = 0
sq5 = 0
sq6 = 0
sq7 = 0
sq8 = 0
sq9 = 0
turn = 1
Each "sq" corresponds to the square it represents. "Turn" is a variable that shows whose turn it is: 1 = X, 2 = O.
Under the 1st hotspot's properties, there is:
- Code: Select all
Select Case True
Case ((turn = 1) And (sq1 = 0))
Hotspot(1).Picture = "x.bmp"
sq1 = 1
CheckX
turn = 2
Case ((turn = 2) And (sq1 = 0))
Hotspot(1).Picture = "o.bmp"
sq1 = 2
CheckO
turn = 1
Case (sq1 = 1)
MsgBox "Something is already there!"
Case (sq1 = 2)
MsgBox "Something is already there!"
End Select
If sq1 = 0, nothing is there. If sq1 = 1, x is there, and if sq1 = 2, o is there.
The error I get when I click on the hotspot is:
Type mismatch: 'Picture'
Can someone help?