|
-
April 22nd, 2011, 06:22 PM
#1
Where did my background worker go?
He is not doing his job. I had some functions to run when my program is open and I noticed that the GUI was not coming up until the functions were completed.
So I looked up an example of how to fix it by using a background worker. So I followed the code exactly and all syntax checks out and my program opens nice and fast. However the functions are never executed 
Here is the code:
public MainWindow()
{
InitializeComponent();
BackgroundWorker OnLoad = new BackgroundWorker();
OnLoad.DoWork += (s, e) =>
{
updateListDatabases();
updateUserApps();
};
OnLoad.RunWorkerAsync();
}
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
|