Click here to Skip to main content
15,901,284 members
Home / Discussions / C#
   

C#

 
QuestionDifference between C and Visual C. Pin
Razanust24-Mar-10 3:03
Razanust24-Mar-10 3:03 
AnswerRe: Difference between C and Visual C. Pin
Not Active24-Mar-10 3:05
mentorNot Active24-Mar-10 3:05 
GeneralRe: Difference between C and Visual C. Pin
Som Shekhar24-Mar-10 4:42
Som Shekhar24-Mar-10 4:42 
GeneralRe: Difference between C and Visual C. Pin
Pete O'Hanlon24-Mar-10 7:48
mvePete O'Hanlon24-Mar-10 7:48 
GeneralRe: Difference between C and Visual C. Pin
Som Shekhar24-Mar-10 7:53
Som Shekhar24-Mar-10 7:53 
AnswerRe: Difference between C and Visual C. Pin
yu-jian26-Mar-10 7:14
yu-jian26-Mar-10 7:14 
QuestionWorking with the UI while multithreading Pin
Islorvat24-Mar-10 3:02
Islorvat24-Mar-10 3:02 
AnswerRe: Working with the UI while multithreading Pin
Luc Pattyn24-Mar-10 3:31
sitebuilderLuc Pattyn24-Mar-10 3:31 
you got it wrong.
Having Control.InvokeRequired and Control.Invoke the way you did is just fine, however they cause the else block in ProgressUpdate to execute on the GUI thread (that was the intention all along), so that else block should NOT contain lengthy operations nor calls to Thread.Sleep

You should perform all timing by:
- using timers;
- OR using whatever you like on YOUR threads;
- but not by using Thread.Sleep on the GUI thread.

So a better approach would be to have the thread execute some method, say Progress, which contains any delay you like, and calls ProgressUpdate (the new one without any Sleep) to update the GUI.

Smile | :)

AnswerRe: Working with the UI while multithreading Pin
Tim Weckx24-Mar-10 3:58
Tim Weckx24-Mar-10 3:58 
GeneralRe: Working with the UI while multithreading Pin
Islorvat24-Mar-10 4:27
Islorvat24-Mar-10 4:27 
QuestionNews feed popup desktop application Pin
Sherif W. Girgis24-Mar-10 2:39
Sherif W. Girgis24-Mar-10 2:39 
AnswerRe: News feed popup desktop application Pin
Not Active24-Mar-10 3:03
mentorNot Active24-Mar-10 3:03 
QuestionTo save the file Pin
v17.poornima24-Mar-10 2:01
v17.poornima24-Mar-10 2:01 
AnswerRe: To save the file Pin
Richard MacCutchan24-Mar-10 3:43
mveRichard MacCutchan24-Mar-10 3:43 
Questionembedd flash in winform in mono .net Pin
melihcicek24-Mar-10 2:01
melihcicek24-Mar-10 2:01 
AnswerRe: embedd flash in winform in mono .net Pin
CDP180224-Mar-10 2:13
CDP180224-Mar-10 2:13 
GeneralRe: embedd flash in winform in mono .net Pin
melihcicek24-Mar-10 2:49
melihcicek24-Mar-10 2:49 
GeneralRe: embedd flash in winform in mono .net Pin
Tony Richards24-Mar-10 6:42
Tony Richards24-Mar-10 6:42 
Questionvoice recognition Pin
kingsto24-Mar-10 1:04
kingsto24-Mar-10 1:04 
AnswerRe: voice recognition Pin
Rob Philpott24-Mar-10 1:11
Rob Philpott24-Mar-10 1:11 
AnswerRe: voice recognition PinPopular
OriginalGriff24-Mar-10 1:13
mveOriginalGriff24-Mar-10 1:13 
AnswerRe: voice recognition Pin
Keith Barrow24-Mar-10 1:17
professionalKeith Barrow24-Mar-10 1:17 
JokeRe: voice recognition Pin
Calla24-Mar-10 1:56
Calla24-Mar-10 1:56 
QuestionAdd Custom Color in ColorDialog Pin
Anubhava Dimri23-Mar-10 23:44
Anubhava Dimri23-Mar-10 23:44 
AnswerRe: Add Custom Color in ColorDialog Pin
sanforjackass24-Mar-10 0:21
sanforjackass24-Mar-10 0:21 

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.