public void RefreshIssues() { RaisePropertyChangedEvent("Issues"); if (Issues != null && Issues.Count() > 0) { CurrentIssue = Issues.Last(); } }
public MainViewModel(StackPanel pageSelectionStackPanel, Grid pageLayoutGrid) { CreateAdModuleView(); ClassifiedView = CollectionViewSource.GetDefaultView(ClassifiedAd.All); ClassifiedView.Filter = ClassifiedFilter; _pageLayout = new AdsOnPageManager(this, pageLayoutGrid); PageSelectionStackPanel = pageSelectionStackPanel; if (Issues.Count() > 0) { CurrentIssue = Issues.Last(); } _instance = this; }