I have a console application that inits 4 theads to perform a long task. I want my program to wait until the threads are complete, and then complete the program execution. Is there a way to stop the program from executing, letting the threads complete their job?
Threading.Thread.Join is what you are looking for.
Edit: Examples here
Load your application after those threads are joined e.g:
Thread1.join();
Thread2.join();
Thread3.join();
Thread4.join();
startApplication();
If you could provide me in more detail i can help you better.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With