private void Window_IsVisibleChanged(object sender, DependencyPropertyChangedEventArgs e) { if (e.NewValue is bool) { if ((bool)e.NewValue && Properties.Settings.Default.ReloadOnOpen) { WebBrowser.ForceReload(); } } }