void browser_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { string message = "{\"type\":\"error\",\"url\":\"" + e.Uri.OriginalString + "\"}"; PluginResult result = new PluginResult(PluginResult.Status.ERROR, message); result.KeepCallback = true; this.DispatchCommandResult(result, NavigationCallbackId); }
private void ApplicationNavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { if (e.Exception is WebException) { //MessageBox.Show(Strings.exceptionSiteIsNotAvailable + e.Uri.ToString()); e.Handled = true; } }
void browser_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { string message = "{\"type\":\"navigationError\",\"location\":\"" + e.Uri.AbsoluteUri + "\"}"; PluginResult result = new PluginResult(PluginResult.Status.ERROR, message); result.KeepCallback = true; this.DispatchCommandResult(result); }
private void Application_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { if (!e.Handled) { MessageBox.Show(e.Exception.ToString()); Shutdown(e.Exception.HResult); } }
void webBrowser_WebView_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { var url = e.Uri.ToString(); if (sender == m_webView) { MainPage.m_d3dInterop.csActionResult_CCWeb_LoadedPage("CCWebView::LoadedPage", url, false); } }
private void BrowserNavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { e.Handled = true; if (e.Exception != null) { DisplayError(); } }
private void Application_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { if (e.Exception is System.Net.WebException) { MessageBox.Show("Сайт " + e.Uri.ToString() + " не доступен :("); e.Handled = true; } }
private void Application_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { if (e.Exception is System.Net.WebException) { MessageBox.Show("站点" + e.Uri.ToString() + "不可达"); // 抑制错误,使应用程序正常运行 e.Handled = true; } }
/// <summary> /// Handler for Frame's navigation failed event /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void OnWebContentHostNavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { // Handle the event - no need to log here, since we're navigating to web content this will only work when // online and may fail for any number of reasons // If event is not handled, exception will be thrown by the Frame element. if (!e.Handled) { e.Handled = true; } }
void webBrowser_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { if (this.currentEvent != null) { Utils.log(this.currentEvent.name + ": NavigationFailed (" + e.Uri.ToString() + ")"); if (this.OnEventFailed != null) { OnEventFailed(this, new EventSenderArgs(this.currentEvent)); } } cleanup(); }
private void browser_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { var g = new Microsoft.Xna.Framework.Game(); var title = "Ups!"; var message = "Algo salió mal.\r\n¿Estás seguro tienes conexión a Internet?"; var ans = MessageBox.Show(message, title, MessageBoxButton.OKCancel); if (ans == MessageBoxResult.OK) { title = "¿Quieres instalar el certificado en tu teléfono?"; message = "El SIDING tiene problemas con el certificado de seguridad.\r\n" + "Si no has seguido las instrucciones, pon Ok para que te expliquemos qué debes hacer.\r\n\r\n" + "Si ya hiciste el trámite pon cancelar e intenta más tarde. Saldrás de la app."; ans = MessageBox.Show(message, title, MessageBoxButton.OKCancel); if (ans != MessageBoxResult.OK) { g.Exit(); } else { title = "Instrucciones 1/2"; message = "1. Desde un computador baja el archivo http://bit.ly/dsCertf\r\n" + "2. Adjunta el archivo y envíalo por email a la cuenta que tienes configurada en la app Mail de tu equipo Windows Phone.\r\n\r\n" + "Cuando estes listo pon Ok para seguir con los pasos."; ans = MessageBox.Show(message, title, MessageBoxButton.OK); if (ans != MessageBoxResult.OK) { g.Exit(); } title = "Instrucciones 2/2"; message = "1. Desde tu smartphone ve a la app Mail y revisa el correo que te acabas de enviar.\r\n" + "2. Descarga el archivo adjunto .pem haciendo tap en el nombre.\r\n" + "3. Abre el archivo adjunto. Si todo va bien debe aparecer un \"escudo\" de ícono.\r\n" + "4. Acepta instalar el certificado de seguridad.\r\n\r\n" + "Una vez hecho todo esto, reinicia directSiding. Tap Ok para salir."; MessageBox.Show(message, title, MessageBoxButton.OK); g.Exit(); } } else { title = "¡Conéctate a Internet antes!"; message = "Es necesario que actives tu conexión de datos o Wi-Fi para continuar.\r\n" + "Tap Ok para salir"; MessageBox.Show(message, title, MessageBoxButton.OK); g.Exit(); } }
async void defaultHttpAuthHandler(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { var exception = e.Exception as WebBrowserNavigationException; if (exception != null && exception.StatusCode == System.Net.HttpStatusCode.Unauthorized) { Debug.WriteLine("Got 401 while navigating to " + e.Uri.ToString()); var handler = new HttpAuthRequestHandler(); e.Handled = await handler.handle(sender as WebBrowser, e.Uri); if (e.Handled) { ((WebBrowser)sender).Navigate(e.Uri); } } }
private void GapBrowser_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { Debug.WriteLine("GapBrowser_NavigationFailed :: " + e.Uri.ToString()); }
/// <summary> /// Invoked when Navigation to a certain page fails /// </summary> /// <param name="sender">The Frame which failed navigation</param> /// <param name="e">Details about the navigation failure</param> void OnNavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { throw new Exception($"Failed to load {e.Uri}: {e.Exception}"); }
private void RhodesWebBrowser_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { // TODO: WebView NavigationFailed - do we need this? }
private void ContentFrame_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { e.Handled = true; }
protected virtual new void OnNavigationFailed(System.Windows.Navigation.NavigationFailedEventArgs e) { }
private void App_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { Debug.WriteLine("App.NavigationFailed()"); }
// If frame naviagate failed, popup an error window. private void Frame_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { e.Handled = true; new ErrorWindow(e.Exception.Message).Show(); }
void webBrowser1_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { }
protected virtual void OnNavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { NavigationStatus = WebBrowserNavigationStatus.Failed; }
private void Frame_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { ErrorText.Visibility = System.Windows.Visibility.Visible; ErrorText.Text = e.Exception.Message; e.Handled = true; }
private void RichDescFrame_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { Logger.ReportError("Navigation to Rich Description failed. Error: " + e.Exception.Message); RichDescFrame.Visibility = Visibility.Hidden; e.Handled = true; }
/*In case there a page is not loaded, the following function will load an Error page*/ private void frameContainer_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { e.Handled = true; frameContainer.Navigate(new Uri("/Pages/ErrorPage.xaml", UriKind.Relative)); }
private void Application_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { }
void _browser_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { fail(); }
private void PlaceHolder_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { Debug.WriteLine(GetCurrentMethod()); }
private void App_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { logger.Log("App_NavigationFailed"); }
private void mcs2_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e) { progresshow.IsIndeterminate = false; }
void WebView_NavigationFailed(object sender, System.Windows.Navigation.NavigationFailedEventArgs e)