abenitez77
Registered User.
- Local time
- Today, 04:50
- Joined
- Apr 29, 2010
- Messages
- 141
I am looping thru all forms...and i have more than 1,000. looking for the forms that start with the prefix "DYN_" & MyReportListID. Then when I find one, I am copying those forms and resetting properties on them. Looping thru all forms will take a little less than a minute. Is there a way to put the forms I need into an array and loop thru the array?
Code:
odelfrm = "DYN_" & MyReportListID
lenfrm = Len(modelfrm)
frmCnt = CurrentProject.AllForms.count
With CurrentProject
For Each aob In .AllForms
nr = nr + 1
If UCase(Mid(aob.Name, 1, lenfrm)) = "DYN_" & MyReportListID Then
' Do something here.....
Endif
Next aob
End With