I have a BackgroundWorker that I use on a Search. Two different Searches can be done, one to a SQL DB and another to an Accpac DB. To accommodate for slow execution time to the Accpac DB, I use Thread.Sleep. The problem is, when I do a search on my SQL DB, I give parameters stating it should only return active records. If I move the Thread.Sleep to accommodate for my Accpac search, then my SQL results return all records instead of Active only. If I move Thread.Sleep to accommodate for my SQL search, then there are issues on the Accpac search results returned.
Are there any other alternatives other than Thread.Sleep?