"Synchronize is a special function provided by TThread. It acts like a critical section for accessing forms controlled by the main thread (the thread which is represented by your Project Source.cpp file). You pass it a pointer to a function in your thread class and Synchronize executes it as if it were a function in the main thread. Only one thread at a time can execute in the main thread context, so Synchronize lets you serialize access to main thread resources like controls and tables - where parallel (and potentially interrupted) access by multiple threads could leave important data structures in an inconsistent (and thus crash-prone) state."
Hope this helps.
------------------------------
Wisdom doesn't always come with age. Sometimes age comes alone.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.