Click here to Skip to main content
15,905,316 members
Home / Discussions / C#
   

C#

 
QuestionXmlTextReader in PDA Pin
AhsanS11-Jun-06 0:07
AhsanS11-Jun-06 0:07 
AnswerRe: XmlTextReader in PDA Pin
Colin Angus Mackay11-Jun-06 0:21
Colin Angus Mackay11-Jun-06 0:21 
GeneralRe: XmlTextReader in PDA Pin
AhsanS11-Jun-06 0:23
AhsanS11-Jun-06 0:23 
GeneralRe: XmlTextReader in PDA Pin
Yustme11-Jun-06 4:31
Yustme11-Jun-06 4:31 
QuestionImport excel sheet in sql database Pin
John Ahmad10-Jun-06 23:03
John Ahmad10-Jun-06 23:03 
AnswerRe: Import excel sheet in sql database Pin
Stanciu Vlad11-Jun-06 5:08
Stanciu Vlad11-Jun-06 5:08 
QuestionHow to implement abort functionality Pin
engsrini10-Jun-06 20:55
engsrini10-Jun-06 20:55 
AnswerRe: How to implement abort functionality Pin
Jun Du11-Jun-06 2:13
Jun Du11-Jun-06 2:13 
I can give you some thoughts based on my experience. A thread can be terminated in three ways:
1) The thread functio returns. (Recommended)
2) The thread kills itself. (Avoid)
3) Somebody else kills this thread. (Avoid)

You should always design your thread functions so that they returns when you want the thread to terminate. This way, you can clean up things, e.g., closing read/write files. In practice, use some thread synchronization objects, such as event, mutex or semaphore. When the calling thread wants your testing thread to terminate/abort, send a signal through one of these sychronization objects. This design is pretty mature and should resolve your stability issue.

Hope this answers your questions.

- It's easier to make than to correct a mistake.
QuestionHow to Specify DialogResult Pin
Richard Andrew x6410-Jun-06 18:28
professionalRichard Andrew x6410-Jun-06 18:28 
AnswerRe: How to Specify DialogResult Pin
Super Lloyd10-Jun-06 20:16
Super Lloyd10-Jun-06 20:16 
GeneralRe: How to Specify DialogResult Pin
Richard Andrew x6410-Jun-06 20:17
professionalRichard Andrew x6410-Jun-06 20:17 
GeneralRe: How to Specify DialogResult Pin
Super Lloyd10-Jun-06 20:46
Super Lloyd10-Jun-06 20:46 
Questionsqlconnection by_IP Pin
Mohammed Elkholy10-Jun-06 11:09
Mohammed Elkholy10-Jun-06 11:09 
AnswerRe: sqlconnection by_IP Pin
Guffa10-Jun-06 11:19
Guffa10-Jun-06 11:19 
Questionrunning two UI threads in same application Pin
venkyp10-Jun-06 10:43
venkyp10-Jun-06 10:43 
Questiontext files Pin
rcwoods10-Jun-06 9:13
rcwoods10-Jun-06 9:13 
AnswerRe: text files Pin
Guffa10-Jun-06 11:06
Guffa10-Jun-06 11:06 
QuestionHow can I alter the property of the main form control from a secondary form? Pin
AngryC10-Jun-06 7:45
AngryC10-Jun-06 7:45 
AnswerRe: How can I alter the property of the main form control from a secondary form? Pin
led mike10-Jun-06 17:06
led mike10-Jun-06 17:06 
AnswerRe: How can I alter the property of the main form control from a secondary form? Pin
engsrini10-Jun-06 20:48
engsrini10-Jun-06 20:48 
GeneralRe: How can I alter the property of the main form control from a secondary form? Pin
AngryC11-Jun-06 11:58
AngryC11-Jun-06 11:58 
GeneralRe: How can I alter the property of the main form control from a secondary form? Pin
engsrini20-Jun-06 8:03
engsrini20-Jun-06 8:03 
QuestionIf an exception is thrown inside a lock {...} [modified] Pin
Marc Clifton10-Jun-06 7:24
mvaMarc Clifton10-Jun-06 7:24 
AnswerRe: If an exception is thrown inside a lock {...} [modified] Pin
Ravi Bhavnani10-Jun-06 9:42
professionalRavi Bhavnani10-Jun-06 9:42 
GeneralRe: calculating diff between 2 dates Pin
Guffa10-Jun-06 8:49
Guffa10-Jun-06 8:49 

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.