public void SetRedditValuesFromToast(object parameter) { RedditItem item = new RedditItem(); string jsonString = parameter as string; if (!String.IsNullOrEmpty(jsonString)) { if (item.TryParse(jsonString)) { RedditTitleBlock.Text = item.Title; Uri uri; if (item.TryUrlToUri(out uri)) { RedditLinkButton.NavigateUri = uri; } if (item.TryPermalinkToUri(out uri)) { RedditCommentsButton.NavigateUri = uri; } } } }
public void SetRedditValuesFromToast(object parameter) { RedditItem item = new RedditItem(); string jsonString = parameter as string; if (!String.IsNullOrEmpty(jsonString)) { if (item.TryParse(jsonString)) { RedditTitleBlock.Text = item.Title; Uri uri; if (item.TryUrlToUri(out uri)) { RedditLinkButton.NavigateUri = uri; } if (item.TryPermalinkToUri(out uri)) { RedditCommentsButton.NavigateUri = uri; } } } }