Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

how to tell when thread has finished vb.net

Posted on 2011-03-25
5
Medium Priority
?
449 Views
Last Modified: 2012-05-11
Hi

I need to be able to tell when a thread has finished so I can run some procedures. I do not want to sit and wait for it so is there an event or something that is raised?

Thanks Nick Steele
0
Comment
Question by:nsteele84
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 35218493
There are many ways to do it...the "best" approach is highly dependent upon the type of application and how the "flow" of what you're doing fits into the "big picture".

Can you give more details on the type of app, version of VB, what is being done, and when "it" is firing off?
0
 

Author Comment

by:nsteele84
ID: 35218581
The application is an FTP upload. I use the thread to upload the files but when it is finished I need to update a tree view which is in the main thread.
0
 
LVL 86

Expert Comment

by:Mike Tomlinson
ID: 35218585
Ok...so we're talking a WinForms app then?  What version VB?
0
 
LVL 17

Accepted Solution

by:
nepaluz earned 2000 total points
ID: 35218742
use the backgroundworker to run your threads and handle the OnComplete event. e.g have a messagebox or update a label with your chosen notification
0
 

Author Closing Comment

by:nsteele84
ID: 35219756
Thats what I was looking for thanks
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you're writing a .NET application to connect to an Access .mdb database and use pre-existing queries that require parameters, you've come to the right place! Let's say the pre-existing query(qryCust) in Access takes a Date as a parameter and l…
Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
Suggested Courses

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question