Click here to Skip to main content
15,891,976 members
Home / Discussions / C#
   

C#

 
GeneralRe: Want to map two keys to a value Pin
Jordanwb8-May-08 10:47
Jordanwb8-May-08 10:47 
GeneralRe: Want to map two keys to a value Pin
Dave Kreskowiak8-May-08 13:26
mveDave Kreskowiak8-May-08 13:26 
GeneralRe: Want to map two keys to a value Pin
Andrew Rissing9-May-08 4:44
Andrew Rissing9-May-08 4:44 
AnswerRe: Want to map two keys to a value Pin
Gareth H8-May-08 7:43
Gareth H8-May-08 7:43 
GeneralRe: Want to map two keys to a value Pin
Jordanwb8-May-08 10:09
Jordanwb8-May-08 10:09 
AnswerRe: Want to map two keys to a value Pin
PIEBALDconsult8-May-08 14:08
mvePIEBALDconsult8-May-08 14:08 
QuestionSynchronizationContext VS backgroundworker Pin
reivilos8-May-08 6:01
reivilos8-May-08 6:01 
AnswerRe: SynchronizationContext VS backgroundworker Pin
Judah Gabriel Himango8-May-08 7:31
sponsorJudah Gabriel Himango8-May-08 7:31 
reivilos wrote:
What is the best way to handle this?

The UI thread should update the business objects. If the background thread needs to tell the UI to update the business object, use a SynchronizationContext and Post to it from the background thread. If you need to spawn a new thread yourself that lasts for the duration of your app, don't use a threadpool thread, create your own.

reivilos wrote:
Is it right to create a never ending Background worker

Don't do that, it's not what the BackgroundWorker was designed for. Since it's using a threadpool thread, you certainly shouldn't do this. Create your own thread and make changes to the business objects by Posting to the UI thread's SynchronizationContext.


Tech, life, family, faith: Give me a visit.
From my latest post: "It's sobering to watch: the whole country stops for 2 minutes as a siren is blast to remember the 22,437 victims of terror and soldiers who died in defense of Israel..."
The apostle Paul, modernly speaking: Epistles of Paul

Judah Himango


Questionusing DLL in Vista 64bit, Bad Image Format Exception Pin
sharp_k8-May-08 5:32
sharp_k8-May-08 5:32 
AnswerRe: using DLL in Vista 64bit, Bad Image Format Exception Pin
Judah Gabriel Himango8-May-08 7:42
sponsorJudah Gabriel Himango8-May-08 7:42 
GeneralRe: using DLL in Vista 64bit, Bad Image Format Exception Pin
sharp_k8-May-08 14:44
sharp_k8-May-08 14:44 
GeneralRe: using DLL in Vista 64bit, Bad Image Format Exception Pin
Judah Gabriel Himango9-May-08 4:51
sponsorJudah Gabriel Himango9-May-08 4:51 
GeneralRe: using DLL in Vista 64bit, Bad Image Format Exception Pin
sharp_k9-May-08 5:34
sharp_k9-May-08 5:34 
GeneralRe: using DLL in Vista 64bit, Bad Image Format Exception Pin
Judah Gabriel Himango9-May-08 5:47
sponsorJudah Gabriel Himango9-May-08 5:47 
GeneralRe: using DLL in Vista 64bit, Bad Image Format Exception Pin
sharp_k9-May-08 6:56
sharp_k9-May-08 6:56 
GeneralRe: using DLL in Vista 64bit, Bad Image Format Exception Pin
Judah Gabriel Himango9-May-08 8:36
sponsorJudah Gabriel Himango9-May-08 8:36 
GeneralRe: using DLL in Vista 64bit, Bad Image Format Exception Pin
sharp_k9-May-08 10:18
sharp_k9-May-08 10:18 
QuestionArrayList worked unexpectedly... Pin
natsuyaki8-May-08 4:39
natsuyaki8-May-08 4:39 
AnswerRe: ArrayList worked unexpectedly... Pin
Anthony Mushrow8-May-08 6:13
professionalAnthony Mushrow8-May-08 6:13 
AnswerRe: ArrayList worked unexpectedly... Pin
Luc Pattyn8-May-08 6:25
sitebuilderLuc Pattyn8-May-08 6:25 
AnswerRe: ArrayList worked unexpectedly... Pin
Gareth H8-May-08 7:46
Gareth H8-May-08 7:46 
AnswerRe: ArrayList worked unexpectedly... Pin
GuyThiebaut8-May-08 8:01
professionalGuyThiebaut8-May-08 8:01 
GeneralRe: ArrayList worked unexpectedly... Pin
Guffa8-May-08 10:49
Guffa8-May-08 10:49 
GeneralRe: ArrayList worked unexpectedly... Pin
natsuyaki10-May-08 21:24
natsuyaki10-May-08 21:24 
QuestionProgramaticly stop & start sql server? Pin
Harvey Saayman8-May-08 4:33
Harvey Saayman8-May-08 4:33 

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.