|
-
Nov 1st, 2000, 05:56 PM
#7
Hyperactive Member
Regarding optimizing your loops, don't use an expression as the limits in a For... Statement; use variables instead. The limiting expressions get evaluated every iteration. For instance, say you are processing a string:
' This is Slow
For lng = 1 to Len(strText)
' This is Fast
lngCount = Len(strText)
For lng = 1 to lngCount
Don't use immediate ifs, as in:
var = IIf(expr,True,False)
because they execute four times slower than regular If..Then..Else constructs. (And the readability isn't so hot, either.)
For MS-Access, when you create reports, add Docmd.Maximize to the Activate event and Docmd.Restore to the Deactivate event. It's a nice touch.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|