| | |
Working with threads
Thread Solved |
•
•
Join Date: Jul 2009
Posts: 7
Reputation:
Solved Threads: 2
Hello everyone,
I'm quite familiar with Delphi, but I'm new to using threads and so I've got a question. Here's what I'm trying to do:
I'm using the brilliant VirtualTreeView component and I wish to add to it from a thread. The tree is on the main form and is not visible and the only thing that accesses this tree is the thread.
My understanding is that to access anything on the form I should use Synchronize(), but since the thread is the only thing that uses the component, do I still need this procedure?
Sub Xero
I'm quite familiar with Delphi, but I'm new to using threads and so I've got a question. Here's what I'm trying to do:
I'm using the brilliant VirtualTreeView component and I wish to add to it from a thread. The tree is on the main form and is not visible and the only thing that accesses this tree is the thread.
My understanding is that to access anything on the form I should use Synchronize(), but since the thread is the only thing that uses the component, do I still need this procedure?
Sub Xero
•
•
Join Date: Apr 2005
Posts: 3
Reputation:
Solved Threads: 0
•
•
•
•
Found the answer myself. And it's yes, I do need to call Synchronize() or the program hangs at random points.
Sub Xero
Honestly,
TMultiReadExclusiveWriteSynchronizer is MUCH better than Syncronize. Makes better use of memory and thread execution will stand much less of a chance of hanging.
Cheers
![]() |
Similar Threads
- Running java command thru java program (Java)
- The quick 'n' dirty ultra simple vBulletin SEO hack (Existing Scripts)
- Semafore in Windows problem (C++)
- Dell Inspiron 2600 Laptop LCD Blank White (Monitors, Displays and Video Cards)
- explorer.exe refusing to run (Viruses, Spyware and other Nasties)
- Stuck in GUI (Python)
- XML parser routine: broken? (Perl)
- Do you think a non-support Java chat applet is a good idea? (DaniWeb Community Feedback)
Other Threads in the Pascal and Delphi Forum
- Previous Thread: GetDiskSerial
- Next Thread: Integration
| Thread Tools | Search this Thread |





