public MainPage() { dispatcher = Window.Current.CoreWindow.Dispatcher; ToasterFinder toasterFinder = new ToasterFinder(); toasterFinder.ToasterFound += ToasterFinder_ToasterFound; toasterFinder.Start(); this.InitializeComponent(); DarknessLevelSlider.IsEnabled = false; StartToastButton.IsEnabled = false; StopToastButton.IsEnabled = false; }