multy threading wpf
- by Eran
Hey,
I'm using web refernce call in new working thread in my application as follow:
Thread callRunner = new Thread(delegate() { _mediator.IncomingCallDetails(phoneNumber); });
callRunner.Start() ;
the _mediator calls the web refernce and replay to the caller in event as follow:
void IncomingCallComplited(IncomingCallEventArg args)
{
Caller = args.Caller;
Lodgers = args.Lodgers;
PreviousMissions = args.PreviousMissions;
}
Caller ,Lodgers and PreviousMissions are properties of an object that bind to GUI element,as for now the binding works fine and i can see the values from the web refernce in screen my question is should I use Dispatcher in the event or in any other phase ? and if I do can someone please explain why?
Thanks
Eran