2012年12月4日

delphi webbrowser与网页相互操作

摘要: 1.delphi 调用js,触发就是方法:var win: IHTMLWindow2;beginwin := IHTMLDocument2(wbmap.Document).parentWindow;Win.execScript('addAllPoits(' + QuotedStr(strValue) + ')', 'javascript');end;addAllPoits:js的方法strValue:方法参数;'javascript':脚本语言;2.js页面操作触发delphi程序写的方法,主要原理是:修改window.exter 阅读全文

posted @ 2012-12-04 09:27 呼嘎嘎 阅读(2976) 评论(1) 推荐(0) 编辑

delphi 通过webbrowser读取网页上确定标签ID的值

摘要: Edit1.text := ((wbmap.document as IHTMLDocument2).all.item('tname', 0) as ihtmlinputelement).valuedit1.text:= wbmap.OleObject.document.getElementByID('tname').value;wbmap:webbrowser;tname:网页标签ID名; 阅读全文

posted @ 2012-12-04 09:19 呼嘎嘎 阅读(3622) 评论(0) 推荐(0) 编辑

导航