S
scott
I'm trying to dynamically change the string variable "objType", but I'm
getting an error on the "For Each acobjLoop" line below.
How can I change the CurrentProject.objType to either
"CurrentProject.AllForms" or "CurrentProject.AllReports" depending on my
CASE statement?
CODE *************
For i = 1 To 2
Select Case i
Case 1
objType = "AllForms"
Case 2
objType = "AllReports"
End Select
For Each acobjLoop In CurrentProject.objType
' Execute some code
Next i
getting an error on the "For Each acobjLoop" line below.
How can I change the CurrentProject.objType to either
"CurrentProject.AllForms" or "CurrentProject.AllReports" depending on my
CASE statement?
CODE *************
For i = 1 To 2
Select Case i
Case 1
objType = "AllForms"
Case 2
objType = "AllReports"
End Select
For Each acobjLoop In CurrentProject.objType
' Execute some code
Next i