 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Lion-O Guest
|
Posted: Fri Mar 17, 2006 11:03 am Post subject: Using COM objects in new threads |
|
|
Hello
I am after some advice. I have a created a simple menu application
which is used to execute various COM objects. Each COM object is
created in a seperate thread and run. These COM objects (apartment
threading model?) can then fire up various DLL functions. The reason
why I took this route was because modal forms in COM objects created in
the main thread caused my main form to disable. I am getting various
access violations, and I am not sure whether this is due to a wrong
program setup. Brief structure below:
Program:
procedure btnclick1
begin
TMyThread.Create //COM Obj1
TMyThread.Create //COM Obj2
end
TMyThread:
procedure Execute
begin
try
//execute COM object that was created in constructor
except
end
end
COM Object:
procedure Fire
begin
//execute DLL function
end
However, I get no access violations if I call the DLL functions from
the thread (No COM object). Of course, this is not an option.
Any help will be appreciated.
Thanks |
|
| Back to top |
|
 |
Riki Wiki Guest
|
Posted: Sun Apr 02, 2006 5:03 pm Post subject: Re: Using COM objects in new threads |
|
|
On 17 Mar 2006 02:50:50 -0800, Lion-O wrote:
| Quote: | Any help will be appreciated.
|
Hoi
You need to repost your question on the Borland news server to make
everybody see it and possibly answer your question. Further, this newsgroup
do not officially exist, use newsgroup b.p.d.com.activex.using.
Take a look here:
<http://tinyurl.com/8m5nw>
which links to
<http://delphi.wikicities.com/wiki/Delphi_Newsgroups> |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|