Skip to main content

Working with Threads

A thread controls the flow of an executable program. By default, a program has one thread called Main Thread. Main Thread starts when control enters in the Main method and it terminates when Main method returns.
If the execution of a program is controlled by more than one thread, it’s called a Multithreaded
Application. Such a program increases the performance and response time of an application. In C#, the System.Threading namespace is used for creating and managing thread(s) in a multithreaded application.
A thread can be created by using System.Threading.Thread class. A thread can only be manipulated on a
method. For example, MainThread needs a Main method to control the flow of a progam.
In a C# progarm, a thread can be found in any of the following states:

States of a Thread


System.Threading.Thread class contains the following common methods and properties, which are
helpful for managing a thread.

Common Methods and Properties of Thread Class







Comments

Popular posts from this blog

MTA 98-361: How I passed MTA - Software Development Fundamentals?

MTA 98-361: How I passed MTA - Software Development Fundamentals? :) Let’s Define Microsoft Technology Associate     (c) Microsoft     (c) Useful Link Who should take this exam?     (c) Microsoft What Skills do I need to study for the Exam? Check on this :  Microsoft How did I prepare? I have an experience in VB.NET and C#, because way back in College we had a course that focuses on Microsoft Visual Basic .NET and current on my work we are using C#. I must say it was helpful in speeding up the preparation process, but I still take some time in studying. Don't rush on taking the examination, take time to study even it will take you 1 month or even 2 months – it’s okay as long as you passed. Let’s say you passed the exam in 1 week preparation then what? Did you learn something? Did it actually improved your skills? In my opinion, the Certification is just a reward from studying very hard. The most important thing is not j...

Resources/References that can be used in preparing for MTA 98-361 Software Development Fundamentals

Here is the list of  Resources / References   that can be used in preparing for MTA 98-361 :  Programming in C# Jump Start MTA 98-361 Wikiversity (Very Useful) Microsoft : Preparation Resources CBT Nuggets Wiley Book  - Message me, if you want these book, I will give you discount. MTA 98-361 Resources C# Courses Others 1 Others 2 Keywords : Reviewer 98-361 , Resources 98-361 , Exam 98-361 References 1. Exam 98-361 (Step 1) How I Passed Software Development Fundamentals (Exam 98-361) ? Yes! I passed MTA 98-361. It feels great to be a Microsoft Technology Associate in Software Development Fundamentals. Sample MTA Certification - Badge ====================================================== This Story written by Someone on Microsoft Study Group and It helped me a lot to pass 98-361 : I Frickin' Passed!!! - First Attempt!!! ...

Meet the Great Minds behind the Top 10 Most Prominent Programming Languages

When we will think about programming languages, surely Python, Java, Ruby, and many more will cross our minds. However, undeniably, we sometimes tend to forget about the excellent people behind them - the great minds which created these useful programming languages. In this article, we are going to meet the people behind the Top 10 languages that are widely used by developers. Here are they: 1. Guido van Rossum The man behind  Python  which is not only one of the most prominent but also one of the highest-paying programming languages is Guido van Rossum. Based on Vicky Singh Rao's article on Technotification, Guido is a Dutch who was born on January 31, 1956. His language was initially released in 1991. 2. Yukihiro Matsumoto Computer scientist and programmer Yukihiro Matsumoto is behind the object-oriented programming language  Ruby . He was born on April 14, 1965. It was in the middle of 1990s when Matsumoto developed Ruby in Japan. 3. James Arthur Gosling Can...