|
-
Apr 22nd, 2012, 12:10 PM
#1
Thread Starter
Addicted Member
checking thread completion before continuing.
I'm having trouble checking the completion of multiple threads before executing more code.
As an example, I started two threads:
**************************
Dim Thread1 As New System.Threading.Thread(AddressOf wordpress_checker_thread)
Thread1.Start()
Dim Thread2 As New System.Threading.Thread(AddressOf wordpress_checker_thread)
Thread2.Start()
(check if Thread1 and Thread2 finish running)
* continue with more code.
*******************
I'd like to check when these threads are completed.
I've used If Thread1.IsAlive in a timer but that didn't work because I can't pass Thread1 to the Timer handler. I've declared Thread1 globally using public, it does work but only once because when I rerun the code, you can't restart the same Thread twice.
Any suggestion on how to implement this.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|