wait for all threads to complete

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • diwakar09
    New Member
    • Sep 2007
    • 39

    wait for all threads to complete

    is there any function that stops the further execution of the code untill all threads come to complete

    if there is give me a simple example
  • bartonc
    Recognized Expert Expert
    • Sep 2006
    • 6478

    #2
    Originally posted by diwakar09
    is there any function that stops the further execution of the code untill all threads come to complete

    if there is give me a simple example
    Here's something that might work well:[CODE=python]# start all of the threads
    if theFirstThread. isAlive():
    theFirstThread. join()
    # repeat for each thread[/CODE]

    Comment

    Working...