----- Original Message -----
Sent: Thursday, October 16, 2003 2:01
PM
Subject: Re: [DUG]: Threads again
Ross,
My experience with components and threads
is that you should be able to use the Indy Component within your thread
without calling synchronize provided:
a) you manage form destruction well, so
that the component can't be destroyed while the thread is working with
it.
b) you do not have any event handlers in
the component that call methods on the form (This is a great way to make
things go BANG).
c) there is no other code in the form
which works with the Indy Component; it must all live within the
thread.
d) there is no code in the component which
references its owner while the thread is fiddling with it.
e) the component itself does not rely on
non-threadsafe behaviour.
I haven't done a lot with Indy in threads so I
don't know how safe it is going to be to use, but I have done a whole bunch
with IBX in threads and the results have been great.
HTH
Trevor
----- Original Message -----
Sent: Thursday, October 16, 2003 1:13
PM
Subject: [DUG]: Threads again
(D5) I currently have a thread which is
updating a text file. I'm wanting to alter it to
optionally send the file to an ftp server once it's created.
I've written to ftp servers before using Indy.
I need to put the Indy component on a form, so
if I put it on the mainform, can I use it in the thread without using
Synchronize?. Or is Indy quite responsive and would not slow down
the main thread by using Synchronize?
Any ideas?
Regards,
Ross
Levis.