httpwebrequest - Synchronous Call in Windows Phone 7 -


i know cannot make true synchronous call in windows phone 7. however, i'm trying @ least block threads processing until async call made or there timeout. i've tried following, seems app ignores it, abandons call, , doesn't return back. ideas why?

i'm trying update value using value converter during binding.

public manualresetevent _event;  public void getsync() {     _event = new manualresetevent(false);      var wc = new webclient();     wc.openreadcompleted += new openreadcompletedeventhandler(readcompleted);     wc.openreadasync(new uri("my url"));      // block until async call complete     _event.waitone(5000); }  private void readcompleted(object sender, openreadcompletedeventargs e) {     var serializer = new xmlserializer(typeof(myformatter));     // property below accessed in value converter binding     stronglytypedobject = (stobject)serializer.deserialize(e.result);     _event.set(); } 


Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -