|
You could get the state of the current thread by using this line of code
MsgBox(oThread.ThreadState)
Eg:
Here is a code to create a new therad if the thread is nor running.
If oThread.ThreadState <> Threading.ThreadState.Running Then
oThread = New System.Threading.Thread(AddressOf PopulateTreeThread)
oThread.Start()
End If
|
|