uses mshtml;

var    htmldoc: IHTMLDocument2;
      MaxScrollWidth, MaxScrollHeight: Integer;

htmldoc := web.Document as IHTMLDocument2;
MaxScrollHeight := htmldoc.body.getAttribute('ScrollHeight', 0);  //获得滚动条最大高度
MaxScrollWidth := htmldoc.body.getAttribute('ScrollWidth', 0);//获得滚动条最大宽度
Web.OleObject.Document.ParentWindow.ScrollBy(MaxScrollWidth, MaxScrollHeight ); //滚动到最右最下

 

Last modification:December 27th, 2012 at 02:01 pm
如果觉得我的文章对你有用,请随意赞赏