G
Guest
Hi, I experience a ThreadStateException while trying to abort a thread that is in a Suspended state. According to the MSDN documentation if Abort() is called on a thread that has been suspended, the thread is resumed and then aborted. But obviously it is not the case. I even made a construct like
if(simulationThread.ThreadState == ThreadState.Suspended
simulationThread.Resume()
simulationThread.Abort()
The strangest thing is that even though the thread is suspended,this check results to false and the Resume method is not called
What could be the problem and possible solutions
Thanks in advance
Svetoslav
if(simulationThread.ThreadState == ThreadState.Suspended
simulationThread.Resume()
simulationThread.Abort()
The strangest thing is that even though the thread is suspended,this check results to false and the Resume method is not called
What could be the problem and possible solutions
Thanks in advance
Svetoslav