Today, I am studying a small problem. When I open the iQiYi video in the webbrowser of C #, the entire flash is often biased, and there is no control bar on the progress bar.
This problem can be solved only when the screen is restored.
Figure 1 shows webbrowser and Figure 2 shows IE8. The entire webbrowser is biased and there is no control bar.
Then I tried to use various browsers Based on the Microsoft webbrowser control .. This issue occurs when you use vs2010 to build winform, WPF, and Silverlight webbrowser ......
Then I opened Linux and tried firefox without the bug.
So I thought, is there any Firefox control that can be used in. Net. I searched for a gecko engine component based on the. NET platform.
-- Geckofx
Then let down a bunch of things (it also needs flash for Windows Firefox plug-in and xulrunner)
I wrote a small project and tested it. Wow, it solved the problem!
Its method is basically the same as that of. Net webbrowser, so it will not be unfamiliar.
We strongly recommend this component-geckofx
Appendix: simple sample code.
Using system; <br/> using system. collections. generic; <br/> using system. componentmodel; <br/> using system. data; <br/> using system. drawing; <br/> using system. LINQ; <br/> using system. text; <br/> using system. windows. forms; </P> <p> using skybound. gecko; </P> <p> namespace geckofxbrowswer <br/>{< br/> Public partial class form1: form <br/> {<br/> static private string xulrunnerpath = "C: // xulrunner/"; <br/> static private string testurl = "http://www.qiyi.com/dianying/20100521/n14202.html "; </P> <p> private geckowebbrowser browser; <br/> Public form1 () <br/>{< br/> initializecomponent (); </P> <p> skybound. gecko. XPCOM. initialize (xulrunnerpath); </P> <p> browser = new geckowebbrowser (); <br/> browser. parent = This; <br/> browser. dock = dockstyle. fill; <br/>}</P> <p> private void button#click (Object sender, eventargs e) <br/>{< br/> browser. navigate (testurl); <br/>}</P> <p> private void button2_click (Object sender, eventargs E) <br/>{</P> <p >}< br/>
Appendix:
Open Source Address: http://code.google.com/p/geckofx/
Flash plug-in: http://get.adobe.com/flashplayer/otherversions/
Xulrunner: ftp://ftp.mozilla.org/pub/xulrunner/releases/1.9.0.0/runtimes/xulrunner-1.9.en-US.win32.zip