Hi,
I'm wondering is the DIR function is safe for using in multiple threads at the same time within an application.
For example
You use Dir(MyPath) to get the first entry, then loop through with 'file = Dir()' to get all the other entries.
What if, during the middle of this loop another thread did a Dir(MyPath). Would'nt this mess up the rest of the already running thread?
It's not as if you are using a new instance of 'dir' each time.
If so, does anyone know of a thread safe alternative?
Thanks.
I'm wondering is the DIR function is safe for using in multiple threads at the same time within an application.
For example
You use Dir(MyPath) to get the first entry, then loop through with 'file = Dir()' to get all the other entries.
What if, during the middle of this loop another thread did a Dir(MyPath). Would'nt this mess up the rest of the already running thread?
It's not as if you are using a new instance of 'dir' each time.
If so, does anyone know of a thread safe alternative?
Thanks.