> Thanks for the hints, I will try to modify the sample now to make it
> work using inter thread marshalling.
>
> But isn't it possible to have all the threads in the python
> COM server run in a single MTA?
Not when the hosting application (VB in this case) is not in the MTA. You
either need to
Thanks for the hints, I will try to modify the sample now to make it
work using inter thread marshalling.
But isn't it possible to have all the threads in the python COM server
run in a single MTA?
Instead of having several worker threads in several STA's in the python
COM server with marshalli
Mark Hammond schrieb:
> The problem is that the connection server is getting an interface object on
> one thread (the main thread as part of the Advise call) - but the new
> threads you create are using these objects without marshalling the objects.
>
> ie, your new threads are referencing objects
> I attached a zip file that contains a small python COM server and a
> small VB6 client that reproduces the problem.
>
> The server sends events to the VB6 client, but the problem is
> the events
> are handled in different threads in the VB6 client.
>
> I would appreciate it if someone could tell
> I don't know how to tell VB6 to use free-threading or how to
> spawn new
> threads in VB6 that belong to the MTA. Are you sure it's possible, do
> you have more information on how to do this?
I doubt it is possible for the main GUI thread. I believe VB can create
threads via API calls, so they
I tried to run the python COM server from a VB6 ActiveX EXE where I
checked the option "Thread per Object" in the project properties window.
This way, the python COM server component is created in a different thread.
But I still get the error "Class does not support Automation or does not
suppor
Thanks for the reply,
The reason I chose to set the threading model of the python server
component to "free" was that if I do this, then the component gets
created in the MTA of the VB6 GUI process. If I don't do this, the VB6
event handlers are run in different threads than the GUI thread and
> I am trying to build an application where the GUI is implemented as a
> VB6 exe and most of the core functionality is implemented as a python
> COM server that is called by the GUI.
>
> The python COM server has multiple threads running in it and sends
> events once in a while to the VB6 GUI.
>
>
Hello,
I am trying to build an application where the GUI is implemented as a
VB6 exe and most of the core functionality is implemented as a python
COM server that is called by the GUI.
The python COM server has multiple threads running in it and sends
events once in a while to the VB6 GUI.
Th