Dec 04
Finally, i got to know more about ThreadPool which i intended to use it for a while. Basically creating a Thread to perform a task for you is a time consuming thing which achieves some good performance for you with that drawback. But you destroy that thread as soon as you are done with that. In stead, if you use the thread pool, .NET handles the creation and destruction automatically in an efficient manner. Look at the following simple example (got it from : http://msdn.microsoft.com/msdnmag/issues/03/06/NET/).
Example Code: Thread Pool Sample
In the above example, it uses the ThreadPool to get a new thread to execute the delegate. It’s pretty simple and it adds lots of value if you are using even a simple application.
