Pass Object between threads

Vid

New member
Joined
Oct 15, 2009
Messages
1
Programming Experience
1-3
What is the best way to pass objects between threads?

I would like to create a new thread that creates a new object :

Dim myobject as newobject = new newoject

Then in my main thread, I would like to use myobject. Ideally I would like to just assign to a global variable but I don't think that is possible. I think I may have to use some form of delegate function, but not sure of exact syntax.

The new thread will not actually end before I need the object reference in the main thread.

How should I go about this?
 
Last edited:

Latest posts

Back
Top