I'm trying to shorten this list
Page01.Visible = False
Page02.Visible = False
Page03.Visible = False
Page04.Visible = False
Page05.Visible = False
...
Page50.Visible = False
(there are 50 entries in the list)
I have tried writing a for to loop but I am stuck. I have got this far
Dim i As Integer
For i = 1 To 50
Page(i).Visible = False
Next
now I get an error message sayin "expression is not a method or array....."
Can somebody show me what the loop should be please.
mrcw
Page01.Visible = False
Page02.Visible = False
Page03.Visible = False
Page04.Visible = False
Page05.Visible = False
...
Page50.Visible = False
(there are 50 entries in the list)
I have tried writing a for to loop but I am stuck. I have got this far
Dim i As Integer
For i = 1 To 50
Page(i).Visible = False
Next
now I get an error message sayin "expression is not a method or array....."
Can somebody show me what the loop should be please.
mrcw
Comment