I am writing a few codes to create my worm game inside excel and I have bumped into this problem. Every time I activate the macro, it tells me "End Sub Expected" an highlights over the "Sub Movement". Could somebody explain why this is happening and how I can fix it?
Code:
Sub Movement()
Private Sub Text1_KeyDown(KeyCode As Integer, shift As Integer)
Dim Wait As Integer
For Counter = 1 To 1E+43
If KeyCode = vbKeyA Then
ActiveCell.Interior.ColorIndex = 1
ActiveCell.Offset(0, -1).Select
ActiveCell.Interior.ColorIndex = 3
Next Counter
End Sub
End Sub
Thank
~Hydro