Starting a background thread using the Threadpool

Here is a quick and easy way of starting a background process using the Threadpool by way of an inline delegate.

ThreadPool.QueueUserWorkItem(new WaitCallback(
delegate(object stateInfo)
{
    saveToDB();
}));         
  • Share This Post:
  • Share on Twitter
  • Share on Facebook
  • Share on Technorati
posted @ Saturday, May 09, 2009 1:42 PM
Print

Comments on this entry:

No comments posted yet.

Your comment:



(not displayed)


 
 
 
 
 

Live Comment Preview:

 
«February»
SunMonTueWedThuFriSat
2930311234
567891011
12131415161718
19202122232425
26272829123
45678910