c# webbrowser 错误捕获
private void Form1_Load(object sender, EventArgs e) { webBrowser1.Url = new Uri("about:blank"); SHDocVw.WebBrowser axBrowser = (SHDocVw.WebBrowser)this.webBrowser1.ActiveXInstance; axBrowser.NavigateError += new SHDocVw.DWebBrowserEvents2_NavigateErrorEventHandler(axBrowser_NavigateError); webBrowser1.Navigate(@"http://www.baidux.com/reading/show.aspx?id=10000"); } void axBrowser_NavigateError(object pDisp, ref object URL, ref object Frame, ref object StatusCode, ref bool Cancel) { }
桂棹兮兰桨,击空明兮溯流光。