public MemberPage() { ViewData = new NijieMemberViewModel(); InitializeComponent(); this.DataContext = ViewData; #if DEBUG ViewData.MemberId = 17296; #endif }
public void GetMyMemberBookmark(SynchronizationContext context) { try { var result = MainWindow.Bot.ParseMyMemberBookmark(this.Page); this.Members = new ObservableCollection <NijieMemberViewModel>(); foreach (var item in result.Item1) { NijieMemberViewModel m = new NijieMemberViewModel(item); context.Send((x) => { this.Members.Add(m); }, null); } this.IsNextPageAvailable = result.Item2; this.Status = String.Format("Found {0} member(s).", this.Members.Count); } catch (NijieException ne) { this.Status = "Error: " + ne.Message; } }
public void GetMyMemberBookmark(SynchronizationContext context) { try { var result = MainWindow.Bot.ParseMyMemberBookmark(this.Page); this.Members = new ObservableCollection<NijieMemberViewModel>(); foreach (var item in result.Item1) { NijieMemberViewModel m = new NijieMemberViewModel(item); context.Send((x) => { this.Members.Add(m); }, null); } this.IsNextPageAvailable = result.Item2; this.Status = String.Format("Found {0} member(s).", this.Members.Count); } catch (NijieException ne) { this.Status = "Error: " + ne.Message; } }