public FilterOptionsPage()
        {
            InitializeComponent();

            filterOption = filteringOptions.Where(x=>x.Key == app.settings.DateStringHome.Key).FirstOrDefault();

            FilteringOptionsListBox.SelectedIndex = FilteringOptionsListBox.Items.IndexOf(filteringOptions);

            filterOption.Selected = true;

            DataContext = filteringOptions;

            FilteringOptionsListBox.SelectionChanged += new SelectionChangedEventHandler(FilteringOptionsListBox_SelectionChanged);
        }
        private void DoWork(object sender)
        {
            ListBox listbox = sender as ListBox;

            if (listbox.SelectedItem != null)
            {
                var filterSelected = listbox.SelectedItem as FilterOption;

                app.settings.DateStringHome = filterSelected != null ?
                    filteringOptions[filteringOptions.IndexOf(filterSelected)] :
                    app.settings.DateStringHome;

                filterOption.Selected = false;
                filterOption = filterSelected;

                if (filterSelected != null)
                    filterSelected.Selected = filteringOptions[filteringOptions.IndexOf(filterOption)].Selected = true;
            }
        }