|
-
April 4th, 2007, 04:22 AM
#2
Re: How to update a ToolStripProgressBar from a thread
Use a BackgroundWorker, and update the progressbar from the worker's progresschanged event, which is UI thread safe
If youre on 1.1 .net and dont have a BGW, you can get one by googling; its not part of the framework.
If youre on 1.0, upgrade
If you dont want to upgrade, you can call InvokeRequired on the form itself, and if it is needed, Invoke a method tha tupdates the progressbar. Pointless though, when background worker makes it so nice, and painless
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|