How to stop a thread?



How to stop a thread?..

Answer / Ram Vijai

To stop a thread in .NET, you can set its IsAlive property to false and join() the thread. In Python, you can use the thread.join() method to wait for the thread to finish execution. If you need to stop the thread earlier, you can use an event or flag to signal it to exit.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Windows Threads Interview Questions

1.Can anyone tell how to install os manually? and is there any problem to install os? 2. Can anyone tell how to resolve the blue screen error to install os

6 Answers   Wipro,


WHAT IS A DAEMON?

5 Answers   IBM,


How do I kill a process?

1 Answers  


How do you kill tasks?

1 Answers  


What is a p-thread?

1 Answers  


Explain yielding in threading?

1 Answers  


How do you kill a process using pid?

1 Answers  


Which one you will use to implement critical section?

2 Answers   HCL,


Where is taskkill located?

1 Answers  


What is the reason for getting the dialouge box( send this error to microsoft giving options as send to microsoft and dont send ) when we abort from the any work when it was struck.

1 Answers   CTS, HCL,


Explain what is the impact if dns server fails?

1 Answers  


what are the reasons of rebooting the system?

11 Answers   HCL, HP, Mphasis,


Categories