Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1108765
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T02:08:02+00:00 2026-05-17T02:08:02+00:00

Recently our WPF/Entity Framework 4.0 application has become unstable after we began using backgroundworkers

  • 0

Recently our WPF/Entity Framework 4.0 application has become unstable after we began using backgroundworkers in order to load data from the entity. We were doing so in order to have a ‘Please Wait’-spinner graphic running while the BG worker retrieved data from the database, but we began experiencing numerous EF-related connection issues and other inexplicable errors at random times. A post from a Microsoft EF team member seemed to suggest that EF is not ‘thread safe’ and once we removed the BG workers the problems did indeed go away.

This leaves us with a UI-experience issue – we no longer have a nice user-friendly ‘Please-Wait’ spinner running while the data is loading. Does anyone out there have any suggestions as to other ways in which this can be done without placing the data-load into a BG worker?

Thanks

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T02:08:02+00:00Added an answer on May 17, 2026 at 2:08 am

    You can take an in-between step. Instead of a BackgroundWorker, create a single thread that runs until your app closes. That thread creates your connections and handles all database communication. Post messages to it, have it do the work, then receive the results. It will free up the UI, while preventing multiple threads from using EF simultaneously.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We recently updated our WPF application to perform its data synchronisation (using sync framework)
In our WPF applicaiton, we're using WindowStyle=None in order to give our application a
I have been doing windows applications using c#. But recently our management has planned
We recently upgraded our application to .Net 4.0. We were using MbUnit 2.x. With
We recently moved our Windows CE application to the SD Card. Since then the
We've just recently converted our project to using Maven for builds and dependency management,
Microsoft has recently broken our longtime (and officially recommended by them) code to read
Recently our Development user group (Windows) has started showing with a Red Cross in
Recently our client migrated to server with suhosin enabled. Till then we were using
We recently upgraded our rails app from version 3.0.3 to 3.1.0. The application runs

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.