- Where Developers Learn, Share, & Build Careers
I'm one. I am writing NET windows form which is used to import and compute a lot of data. Each import has been made for this purpose, I have created a "main" worker and many "hair" workers.
Import jobs are all listed within a MySQL database and I have set up a function that checks whether the job exists or not.
I need to know that where the child labor is ending their jobs, then control is passed? Do children need to call the main worker again to run and assign child labor to them?
The main worker is called on the form load event, so if I run my main worker for the first time and start work at the level of the child, will the main staff control the form load again?
I would like to write my app every cost money (for API usage / hits) from my import jobs, so I want to write as much app as possible before running a test.
Yes, once you start the background work, you control the return on the calling method, While the work gets processed on another thread.
You can create an event handler that informs you when the background is done.
Private Zero Background Worker 1_Worker (Object Sender, Runwalker Comprehensive Event Argus E) {If (E. Revoked == true) {resultLabel.Text = "Cancel!"; } And if (E. error! = Null) {resultLabel.Text = "Error:" + E. Error. message; } And {resultLabel.Text = "Done!"; }} A full use example can be found here:
Comments
Post a Comment