C
Chris
Hi to all:
I am trying to clean up code in initializing my variables. I would like to
create a loop to handle the resetting of all variables to False. The
variables are SlideXX.(a,b,c, or d). I have tried defining Var1 in the code
below many different ways. The code I am trying to get to work is:
Sub SlideInit()
For i = 70 To 90
If i = 83 Or i = 89 Then GoTo Jmp 'I have no variables on slides 83 or 89
If i >= 85 And i <= 87 Then GoTo Jmp ' I have no variables on slides 85-87
Var1 = "Slide" & CStr(i)
Response = MsgBox(Var1, vbOKOnly, "test") 'Used to see the value of Var1
Var1.a = False
Var1.b = False
Var1.c = False
Var1.d = False
Jmp:
Next i
End Sub
Thanks to all who are able to help.
I am trying to clean up code in initializing my variables. I would like to
create a loop to handle the resetting of all variables to False. The
variables are SlideXX.(a,b,c, or d). I have tried defining Var1 in the code
below many different ways. The code I am trying to get to work is:
Sub SlideInit()
For i = 70 To 90
If i = 83 Or i = 89 Then GoTo Jmp 'I have no variables on slides 83 or 89
If i >= 85 And i <= 87 Then GoTo Jmp ' I have no variables on slides 85-87
Var1 = "Slide" & CStr(i)
Response = MsgBox(Var1, vbOKOnly, "test") 'Used to see the value of Var1
Var1.a = False
Var1.b = False
Var1.c = False
Var1.d = False
Jmp:
Next i
End Sub
Thanks to all who are able to help.