|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Terminating a threadHi
I am using the Suspend method to terminate a thread but it seems that after calling that method the IsLive property is still set to True Is there another way to terminate a thread from the program? Thank you in advance Shmuel Shulman "S Shulman" <smshul***@hotmail.com> schrieb: How To Stop a Thread in .NET (and Why 'Thread.Abort' is Evil)> I am using the Suspend method to terminate a thread but it seems that > after calling that method the IsLive property is still set to True > > Is there another way to terminate a thread from the program? <URL:http://www.interact-sw.co.uk/iangblog/2004/11/12/cancellation> -- M S Herfried K. Wagner M V P <URL:http://dotnet.mvps.org/> V B <URL:http://classicvb.org/petition/> I'm a little concerned about the title of and some of the language used in
the article you highlighted. While I agree totally with the gist of the article I see the the phrase "'Thread.Abort' is Evil" as being inappropriate. Yes, it can be dangerous if is not used properly or used without understanding what it actually does, but, as the author points out, it is actually quite appropriate and, indeed, desirable to use it under certain circumstances. Now, there a number of readers who will know that you know what you are talking about and assume that you agree that "'Thread.Abort' is Evil" and will be guided by that. Whether you do endorse it or not is largely irrelevant. It's a matter of readers perceptions. As we have all seen in the past, such perceptions can easily lead to subsequent posts that contain mis-information and misunderstandings, and, I think you will agree, such posts are not helpful and can have undesirable consequences. I wonder if it might be prudent that, when one posts a link to an article that could be considered 'controversial', that one gives a comment as to the fact that it might not be the only answer and/or whether or not the article is endorsed by the poster. Show quoteHide quote "Herfried K. Wagner [MVP]" <hirf-spam-me-here@gmx.at> wrote in message news:uo%23POStNFHA.2468@tk2msftngp13.phx.gbl... > "S Shulman" <smshul***@hotmail.com> schrieb: >> I am using the Suspend method to terminate a thread but it seems that >> after calling that method the IsLive property is still set to True >> >> Is there another way to terminate a thread from the program? > > How To Stop a Thread in .NET (and Why 'Thread.Abort' is Evil) > <URL:http://www.interact-sw.co.uk/iangblog/2004/11/12/cancellation> > > -- > M S Herfried K. Wagner > M V P <URL:http://dotnet.mvps.org/> > V B <URL:http://classicvb.org/petition/> Bravo and well said!!
Show quoteHide quote "Stephany Young" <noone@localhost> wrote in message news:%23OHxNh1NFHA.3512@TK2MSFTNGP15.phx.gbl... > I'm a little concerned about the title of and some of the language used in > the article you highlighted. > > While I agree totally with the gist of the article I see the the phrase > "'Thread.Abort' is Evil" as being inappropriate. > > Yes, it can be dangerous if is not used properly or used without > understanding what it actually does, but, as the author points out, it is > actually quite appropriate and, indeed, desirable to use it under certain > circumstances. > > Now, there a number of readers who will know that you know what you are > talking about and assume that you agree that "'Thread.Abort' is Evil" and > will be guided by that. Whether you do endorse it or not is largely > irrelevant. It's a matter of readers perceptions. As we have all seen in > the past, such perceptions can easily lead to subsequent posts that > contain mis-information and misunderstandings, and, I think you will > agree, such posts are not helpful and can have undesirable consequences. > > I wonder if it might be prudent that, when one posts a link to an article > that could be considered 'controversial', that one gives a comment as to > the fact that it might not be the only answer and/or whether or not the > article is endorsed by the poster. > > > "Herfried K. Wagner [MVP]" <hirf-spam-me-here@gmx.at> wrote in message > news:uo%23POStNFHA.2468@tk2msftngp13.phx.gbl... >> "S Shulman" <smshul***@hotmail.com> schrieb: >>> I am using the Suspend method to terminate a thread but it seems that >>> after calling that method the IsLive property is still set to True >>> >>> Is there another way to terminate a thread from the program? >> >> How To Stop a Thread in .NET (and Why 'Thread.Abort' is Evil) >> <URL:http://www.interact-sw.co.uk/iangblog/2004/11/12/cancellation> >> >> -- >> M S Herfried K. Wagner >> M V P <URL:http://dotnet.mvps.org/> >> V B <URL:http://classicvb.org/petition/> > >
Hashtable question
Simple LookupAccountName (working) Object variable or With block variable not set. SQL Error How can I get the following functionatilty in Windows Forms ? Anyone know what could cause the following error messages? Print information when ANY control is used Avoiding late binding File locking problem Send a message to a thread |
|||||||||||||||||||||||