Threading possible?

Everything OAD-related that won't fit in the other categories: share general aspects of macro programming and discuss the OAD environment
Post Reply
user-4843
Posts: 11
Joined: Thu Jan 01, 1970 1:00 am

Threading possible?

Post by user-4843 »

Is it possible to have multi-threaded code execution within the macro environment?
I'm following this tutorial and came up with this demo-code:

Code: Select all

from System.Threading import Thread, ThreadStart

def f():

    c = 0
    while True:
        Thread.Sleep(1000)
        print c
        c += 1
        
t = Thread(ThreadStart(f))
t.Start()
However, as soon as I execute t.Start(), ZEN blue 2.3 dies (i.e. the application crashes giving me this error-window):
The attachment Capture.jpg is no longer available
The same happens when I use the ironPython threading module.

Question:
Is it possible to have multi-threaded code execution within the macro environment? The reason I'd like to have this is that I want my GUI to be responsive while executing a bunch of stuff in the background (preferably in a separate Thread).


thanks,
Dominic
Attachments
Capture.jpg
Capture.jpg (17.08 KiB) Viewed 933 times
user-4
Posts: 397
Joined: Thu Jan 01, 1970 1:00 am

Post by user-4 »

Hello Dominic,

Sorry, but Multithreading is not applicable in combination with ZEN.
Post Reply