|
Rank: Newbie Groups: Member
Joined: 4/24/2018 Posts: 2
|
im will set proxy & port in this browser , but this code not work. pleace help me to slove this.
EO.WebEngine.Engine engine1 = EO.WebEngine.Engine.Create("test");
ProxyInfo proxy = new ProxyInfo(ProxyType.HTTP, "178.32.181.66", 3128); engine1.Options.Proxy = proxy;
EO.WebBrowser.ThreadRunner threadRunner = new EO.WebBrowser.ThreadRunner(); EO.WebBrowser.WebView webView1 = threadRunner.CreateWebView();
webView1.Engine = engine1; webControl1.WebView = webView1;
webControl1.WebView.LoadUrl("https://google.com");
|
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,201
|
Hi,
You should not mix up a ThreadRunner and a WebControl. ThreadRunner is for creating a WebView without UI, WebControl is for hosting a WebView with UI. So if your WebView is visible, then first you need to remove your ThreadRunner code.
Second you need to make sure your WebView is NOT created before you set the WebView's Engine property. Setting the WebView's Engine property after the WebView has already been created will raise an exception.
Thanks!
|
|
Rank: Newbie Groups: Member
Joined: 4/24/2018 Posts: 2
|
thank you , editted code :
EO.WebEngine.Engine engine1 = EO.WebEngine.Engine.Create("test"); ProxyInfo proxy = new ProxyInfo(ProxyType.HTTP, "92.222.79.39", 8181); engine1.Options.Proxy = proxy;
EO.WebBrowser.WebView webView1 = new EO.WebBrowser.WebView(); webView1.Engine = engine1; webControl1.WebView = webView1; webControl1.WebView.LoadUrl("http://google.com");
|
|