在winform中使用WebBrowser控件时怎样去除IE的滚动条,在winform中使用WebBrowser控件时怎样去除IE的滚动条
【 tulaoshi.com - ASP.NET 】
很简单的代码,如下:
using mshtml;
object x = System.Reflection.Missing.Value;
axWebBrowser1.Navigate(@"你的网页地址", ref x, ref x, ref x, ref x);

private void axWebBrowser1_DocumentComplete(object sender, AxSHDocVw.DWebBrowserEvents2_DocumentCompleteEvent e)
...{
mshtml.IHTMLDocument2 doc = (mshtml.IHTMLDocument2)axWebBrowser1.Document;
mshtml.IHTMLWindow2 win = (mshtml.IHTMLWindow2)doc.parentWindow;
win.execScript("document.body.style.overflow='hidden';","javascript");
}
来源:http://www.tulaoshi.com/n/20160129/1487709.html
看过《在winform中使用WebBrowser控件时怎样去除IE的滚动条》的人还看了以下文章 更多>>