TastyWheat
Registered User.
- Local time
- Yesterday, 21:30
- Joined
- Dec 14, 2005
- Messages
- 125
Lately I've been using macros to test the performance of my queries and forms. I guess you could do the same thing with a function, but this seems easier to use. To test the performance of a query you'd make a macro like this:
The 'OpenQuery' action will open the query you want to time and the 'Close' action will close the query. The time stops as soon as the query is completely displayed (though it may look like a blip on the screen). Then you have to go into Visual Basic and look in the immediate window. Subtract these two times to get the time it took to load the query. These timings aren't very accurate, but from a human point-of-view there's no difference between 1.05 and 1.06 seconds.
- RunCode
- OpenQuery
- RunCode
- Close
Code:
Public Function PrintTime() As Byte
Debug.Print DateTime.Timer
End Function