B2Ben
Well-known member
- Joined
- Aug 17, 2006
- Messages
- 52
- Programming Experience
- Beginner
I'm digging into some threading for the first time, but Im running into an issue in VS.NET 2005...
I can call StartFade() once, and my DoFade code runs in a separate thread, as it should. Once the DoFade() sub finishes, I would assume the separate thread dies... but it doesn't seem to be happening that way. If I try running StartFade() again, it crashes. I want to start the DoFade() code again. How can I accomplish this?
Thanks!
VB.NET:
Private PicFadeThread As New System.Threading.Thread(AddressOf DoFade)
Public Sub StartFade()
'...do some stuff...
PicFadeThread.Start()
End Sub
Private Sub DoFade()
'...do stuff in my thread...
'(This is not an endless loop... this code ends at some point)
End Sub
Thanks!