C#实现WEB浏览器

private AxSHDocVw.AxWebBrowser axWebBrowser1;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Label label1;
private AxShockwaveFlashObjects.AxShockwaveFlash axShockwaveFlash1;

System.Threading.Thread thread1=new System.Threading.Thread(new System.Threading.ThreadStart(thread_WebBrowse));
thread1.Start();

private void thread_WebBrowse()
{
//这是一个try的用法,遇上错误抛出异常
try
{
Object n=null;
this.axWebBrowser1.Navigate("www.sina.com.cn",ref n,ref n,ref n,ref n);
}
catch(Exception ex)
{
this.label_Output.Text=ex.ToString();
}


 

转载于:https://www.cnblogs.com/leonardleonard/archive/2007/03/24/1927949.html

你可能感兴趣的:(C#实现WEB浏览器)