求delphi 取得uc等非ie的网页内容代码

tom20803862 2017-10-26 10:54:32
var
ShellWindow: IShellWindows;
nCount: integer;
spDisp: IDispatch;
i,ii,im: integer;
vi: OleVariant;
IE1: IWebBrowser2;
IDoc1: IHTMLDocument2;
e: IHTMLElement;
hh : hresult;
Vitem,cns:ihtmlelementcollection;
temps : string;
begin
ShellWindow := CoShellWindows.Create;
nCount := ShellWindow.Count;
for i := 0 to nCount - 1 do
begin
vi := i;
spDisp := ShellWindow.Item(vi);
hh:=spDisp.QueryInterface( iWebBrowser2, IE1 );
hh:=IE1.Document.QueryInterface(IHTMLDocument2,iDoc1);

。。。。


可是对浏览器不行。
...全文
640 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
tom20803862 2017-10-26
  • 打赏
  • 举报
回复
上面代码可取得ie浏览器的网页内容,但取不到uc等其他非ie浏览器的网页内容。
kenlewis 2017-10-26
  • 打赏
  • 举报
回复
不明白,同一个网页,只是在IE浏览器和非IE浏览器可能显示的效果不一样,但是网页内容应该是一样的啊。

1,183

社区成员

发帖
与我相关
我的任务
社区描述
Delphi Windows SDK/API
社区管理员
  • Windows SDK/API社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧