Exception after OnActivate on DownloadStringAsync on Windows Phone 7.x

Topics: Actions & Coroutines
Sep 21, 2013 at 9:12 PM
I have some trouble with activating ViewModel. That situation:

I have ViewModel with property that load data from internet if field is null:
private string _content;
public string Content {
  get {
    if (String.IsNullOrEmpty(_content)) {
      _content = Localization.AppResources.LOADING;
    return _content;
  set {
    if (value != _content) {
      _content = value;

private void LoadBody() {
  try {
    WebClient wc = new WebClient();
    wc.DownloadStringCompleted += new DownloadStringCompletedEventHandler(wc_DownloadStringCompleted);
    wc.DownloadStringAsync(new Uri(String.Format("http://www.diffbot.com/api/article?token={0}&summary=1&url={1}", diffbotToken, this._note.url)));
  catch (Exception ex) {
Before loading complete I press Windows button. I see my home screen

Than I press Back button. But my app crashes without any message after OnActivate method executes.
Sep 24, 2013 at 5:44 PM
Ok, it was my mistake. I forgot remove [DataMember] from one class. After removing all goes fine.