Click here to Skip to main content
15,898,957 members
Home / Discussions / C#
   

C#

 
GeneralRe: File Format Pin
Senseicads16-Sep-09 5:28
Senseicads16-Sep-09 5:28 
GeneralRe: File Format Pin
Luc Pattyn16-Sep-09 5:35
sitebuilderLuc Pattyn16-Sep-09 5:35 
QuestionNullReferenceException was unhandled Pin
Chantal Labrie16-Sep-09 3:27
Chantal Labrie16-Sep-09 3:27 
AnswerRe: NullReferenceException was unhandled Pin
Keith Barrow16-Sep-09 3:33
professionalKeith Barrow16-Sep-09 3:33 
AnswerRe: NullReferenceException was unhandled Pin
Luc Pattyn16-Sep-09 4:05
sitebuilderLuc Pattyn16-Sep-09 4:05 
AnswerRe: NullReferenceException was unhandled Pin
Muhammad Mazhar16-Sep-09 11:27
Muhammad Mazhar16-Sep-09 11:27 
QuestionAdd extension to X509Certificate Pin
Liborac_16-Sep-09 2:27
Liborac_16-Sep-09 2:27 
QuestionLong operation in c#, when does main end? Pin
yeah100016-Sep-09 2:15
yeah100016-Sep-09 2:15 
Hi,
my problem is the following: I wrote a program that downloads lots of images from the internet (not porn though :P). Anywhoo, when i had the entire program in one thread it was not very responsive during the downloading (i used application.doevents in between the downloading cycles). When i added a separate thread for the downloading part i could move the windows around on the screen quickly and with no problems. What i don't quite understand is the why.

What controls the movement of the program window during execution? Does the main thread decide how much processor time it gives for the program and how much for the movement? When does the main thread end? Does it ever end, due to the fact that it has to handle button clicks?

Does main thread end when there are multiple threads? If it does end before the downloading thread, how can the smooth window movement during downloading be explained (as there is still only one thread running?).

TY
AnswerRe: Long operation in c#, when does main end? PinPopular
Luc Pattyn16-Sep-09 2:26
sitebuilderLuc Pattyn16-Sep-09 2:26 
GeneralRe: Long operation in c#, when does main end? Pin
Nagy Vilmos16-Sep-09 2:30
professionalNagy Vilmos16-Sep-09 2:30 
GeneralRe: Long operation in c#, when does main end? Pin
Luc Pattyn16-Sep-09 2:44
sitebuilderLuc Pattyn16-Sep-09 2:44 
GeneralRe: Long operation in c#, when does main end? Pin
musefan16-Sep-09 2:34
musefan16-Sep-09 2:34 
GeneralRe: Long operation in c#, when does main end? Pin
Luc Pattyn16-Sep-09 2:46
sitebuilderLuc Pattyn16-Sep-09 2:46 
GeneralRe: Long operation in c#, when does main end? Pin
musefan16-Sep-09 2:58
musefan16-Sep-09 2:58 
GeneralRe: Long operation in c#, when does main end? Pin
Luc Pattyn16-Sep-09 2:59
sitebuilderLuc Pattyn16-Sep-09 2:59 
GeneralRe: Long operation in c#, when does main end? Pin
musefan16-Sep-09 3:19
musefan16-Sep-09 3:19 
GeneralRe: Long operation in c#, when does main end? Pin
harold aptroot16-Sep-09 2:38
harold aptroot16-Sep-09 2:38 
GeneralRe: Long operation in c#, when does main end? Pin
Nuri Ismail16-Sep-09 2:40
Nuri Ismail16-Sep-09 2:40 
GeneralRe: Long operation in c#, when does main end? Pin
yeah100016-Sep-09 2:48
yeah100016-Sep-09 2:48 
GeneralRe: Long operation in c#, when does main end? Pin
dan!sh 16-Sep-09 3:07
professional dan!sh 16-Sep-09 3:07 
GeneralRe: Long operation in c#, when does main end? Pin
musefan16-Sep-09 3:20
musefan16-Sep-09 3:20 
GeneralRe: Long operation in c#, when does main end? Pin
Luc Pattyn16-Sep-09 3:22
sitebuilderLuc Pattyn16-Sep-09 3:22 
GeneralRe: Long operation in c#, when does main end? Pin
Luc Pattyn16-Sep-09 3:40
sitebuilderLuc Pattyn16-Sep-09 3:40 
GeneralRe: Long operation in c#, when does main end? Pin
N a v a n e e t h16-Sep-09 3:33
N a v a n e e t h16-Sep-09 3:33 
GeneralRe: Long operation in c#, when does main end? Pin
Luc Pattyn16-Sep-09 3:41
sitebuilderLuc Pattyn16-Sep-09 3:41 

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.