[RESOLVED] Threading Problems
Hello
I have a little problem with threads that it's driving me crazy...
I have this application, that when it starts it needs to check some files in hard drive, check some info from the database, and other things where the user doesn't need to interact, i created some threads in the constructor of the main form to handle this job, but i don't understand why, when i try to run some of the threads (didn't figured out if all or some specific), the code of the constructor runs from the start again...
There's a problem when trying to run multiple threads? I already tried the background worker, the thread class and the result it's always the same...
By the way, i have a splash screen that runs in another thread to update the messages.
The code it's similar to this:
vb.net Code:
Public Sub New()
InitializeSplashScreen()
SplashS.UpdateMessage("First Task...")
...
other tasks in the same thread
...
SplashS.UpdateMessage("First thread...")
ThreadUpdateModels()
...
...
End Sub
vb.net Code:
Private Sub ThreadUpdateModels()
Dim thr As New Thread(AddressOf GeralPDM.GetLatestVersion)
With thr
.IsBackground = True
.Start()
End With
End Sub
Some of the functions used by the threads use other functions than the one called directly from the class, is this the problem?
Can i inside a thread call a another thread, i have a situation that i need to check if a connection it's on, before getting the data, so i use another thread?
Thanks
Re: [RESOLVED] Threading Problems
Ha! The default instance rears its ugly head, once again. I wish those things had never been added.
Re: [RESOLVED] Threading Problems