Click here to Skip to main content
15,849,180 members
Home / Discussions / C#
   

C#

 
QuestionAbout MCTS exams Pin
mrcooll9-Jan-07 23:28
mrcooll9-Jan-07 23:28 
AnswerRe: About MCTS exams Pin
Christian Graus9-Jan-07 23:40
protectorChristian Graus9-Jan-07 23:40 
AnswerRe: About MCTS exams Pin
Ravi Bhavnani10-Jan-07 3:30
professionalRavi Bhavnani10-Jan-07 3:30 
QuestionProblem in WebBrowser.Print() Method Pin
stancrm9-Jan-07 23:22
stancrm9-Jan-07 23:22 
AnswerRe: Problem in WebBrowser.Print() Method Pin
blackjack215010-Jan-07 1:02
blackjack215010-Jan-07 1:02 
AnswerRe: Problem in WebBrowser.Print() Method Pin
TrooperIronMan10-Jan-07 4:31
TrooperIronMan10-Jan-07 4:31 
QuestionMulti Threading - All the threads are not completing Pin
jk_just9-Jan-07 23:01
jk_just9-Jan-07 23:01 
AnswerRe: Multi Threading - All the threads are not completing Pin
Luc Pattyn9-Jan-07 23:38
sitebuilderLuc Pattyn9-Jan-07 23:38 
Here are some facts:

By themselves, threads stay alive as long as they have something to do; most likely this
means they are inside a loop (could be a message loop as inside Application.Run, and
in Form.ShowDialog) or they are waiting on something that has not happened yet (such as
Thread.Join).

From outside the thread, a thread could get aborted or killed, to make it stop.

When Thread.IsBackground is true, then that thread will not prevent the app from exiting.

And some suggestions:

- watch your CPU activity (Windows Task Manager, Processes, column: CPU); if not near zero,
your app is still busy (calculating, or looping, anything that exceeds waiting)
- if CPU is near 100% you are probably stuck inside a loop that contains no wait, and also
no delay (something like a polling loop without a Thread.Sleep; a very bad idea!)
- add logging to your threads
- make sure you do not eat Exceptions; they are there for a purpose, act on them, dont
just catch and ignore them
- use Visual Studio to observe and debug your app
- try and avoid potential deadlocks (you know, the situation where multiple threads need
access to the same resources, which are protected in some way, say by locks;
thread 1 grabs resource 1 then tries to grab resource 2, whereas thread 2 grabs
resource 2 then tries to grab resource 1.). If this is too mysterious, find yourself
some articles on the subject (and again add logging to your app, with logging you pretty soon
should notice a deadlock if and when it happens.

Cheers


Luc Pattyn

Questionmodify control properties in usercontrol Pin
Marc Soleda9-Jan-07 21:44
Marc Soleda9-Jan-07 21:44 
GeneralRe: modify control properties in usercontrol Pin
Martin#9-Jan-07 22:06
Martin#9-Jan-07 22:06 
GeneralRe: modify control properties in usercontrol Pin
Marc Soleda9-Jan-07 22:40
Marc Soleda9-Jan-07 22:40 
GeneralRe: modify control properties in usercontrol Pin
Luc Pattyn9-Jan-07 23:46
sitebuilderLuc Pattyn9-Jan-07 23:46 
Questionmarshalling mechanism Pin
s o v a n n9-Jan-07 21:31
s o v a n n9-Jan-07 21:31 
QuestionHow to give application upgrading by .net for the window application,which is done by visual c#? Pin
illusionarylife9-Jan-07 21:28
illusionarylife9-Jan-07 21:28 
AnswerRe: How to give application upgrading by .net for the window application,which is done by visual c#? Pin
Christian Graus9-Jan-07 21:41
protectorChristian Graus9-Jan-07 21:41 
QuestionProblem with assignment using properties... maybe because of IClonable interface Pin
fordge9-Jan-07 21:13
fordge9-Jan-07 21:13 
AnswerRe: Problem with assignment using properties... maybe because of IClonable interface Pin
Stefan Troschuetz9-Jan-07 22:42
Stefan Troschuetz9-Jan-07 22:42 
QuestionHow to view SOAP request/response contents [modified] Pin
blackjack21509-Jan-07 20:41
blackjack21509-Jan-07 20:41 
QuestionHow to check form object created or not Windows App Pin
indiaone9-Jan-07 20:24
indiaone9-Jan-07 20:24 
AnswerRe: How to check form object created or not Windows App Pin
Christian Graus9-Jan-07 20:59
protectorChristian Graus9-Jan-07 20:59 
Questionform maxmizied Pin
md_refay9-Jan-07 20:22
md_refay9-Jan-07 20:22 
AnswerRe: form maxmizied Pin
Christian Graus9-Jan-07 20:59
protectorChristian Graus9-Jan-07 20:59 
GeneralRe: form maxmizied Pin
md_refay9-Jan-07 21:25
md_refay9-Jan-07 21:25 
Question.net remoting proxy Pin
s o v a n n9-Jan-07 19:03
s o v a n n9-Jan-07 19:03 
QuestionIs event handler bound to instance of object, and will it stick? Pin
JoeRip9-Jan-07 18:59
JoeRip9-Jan-07 18:59 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.