G
Guest
I have an application that collects statistics on usage of storage on our
servers - number of directories, number of files, size of files, allocated
by various categories. I originally developed the app using the VBA folder
objects. It worked quite well except for being excruciatingly slow (we have
several terabytes of data to be analyzed). In the hope of speeding it up, I
recoded it using the Windows API file management functions instead of the VBA
folder objects. On some smaller subsets, I got correct results and
significantly improved performance (roughly 3 times as fast), but on the
largest set the application crashed. After some study I isolated the problem
to being a basic RAM cram situation. I finally created my own folder object
as a VBA class module, in the naive hope that the VBA documentation would be
correct - when the object goes out of scope the resources are released.
Didn't help. I have also added the Windows functions to close files and
handles, but that doesn't help either. In fact the resources don't get
released even when the form is closed; the resources are not released until
Access itself is closed.
Any ideas on how to cope with this situation would be greatly appreciated.
servers - number of directories, number of files, size of files, allocated
by various categories. I originally developed the app using the VBA folder
objects. It worked quite well except for being excruciatingly slow (we have
several terabytes of data to be analyzed). In the hope of speeding it up, I
recoded it using the Windows API file management functions instead of the VBA
folder objects. On some smaller subsets, I got correct results and
significantly improved performance (roughly 3 times as fast), but on the
largest set the application crashed. After some study I isolated the problem
to being a basic RAM cram situation. I finally created my own folder object
as a VBA class module, in the naive hope that the VBA documentation would be
correct - when the object goes out of scope the resources are released.
Didn't help. I have also added the Windows functions to close files and
handles, but that doesn't help either. In fact the resources don't get
released even when the form is closed; the resources are not released until
Access itself is closed.
Any ideas on how to cope with this situation would be greatly appreciated.