R
rpatel4
I've got about 5 thread in my application.
One of the threads downloads data from the internet
I gave the UI the highest priority
System.Threading.Thread.CurrentThread.Priority =
System.Threading.ThreadPriority.Normal;
I gave all other threads a lower priority
_threadObject.Priority = System.Threading.ThreadPriority.BelowNormal;
Yet when the background threads are downloading data, the UI is
noticeably slower.
Am I doing something wrong here, is there any other way to get the UI
to have priority over the background?
(While I was writing this I came up with a possible issue -- that a
background thread has acquired a mutex and the UI is blocking until the
background releases that mutex -- I'll check this code for this but if
its not any other solutions?)
One of the threads downloads data from the internet
I gave the UI the highest priority
System.Threading.Thread.CurrentThread.Priority =
System.Threading.ThreadPriority.Normal;
I gave all other threads a lower priority
_threadObject.Priority = System.Threading.ThreadPriority.BelowNormal;
Yet when the background threads are downloading data, the UI is
noticeably slower.
Am I doing something wrong here, is there any other way to get the UI
to have priority over the background?
(While I was writing this I came up with a possible issue -- that a
background thread has acquired a mutex and the UI is blocking until the
background releases that mutex -- I'll check this code for this but if
its not any other solutions?)