procedure TForm1.Button1Click(Sender: TObject);
var
ShellWindow: IShellWindows;
ie :IWebBrowser2;
i,j : Integer;
V,vInput : OleVariant;
sp:IDispatch;
idoc:IHTMLDocument2;
aInput :IHTMLInputButtonElement;
begin
ShellWindow := CoShellWindows.Create;
for i:=0 to ShellWindow.Count-1 do
begin
V := i;
sp := ShellWindow.Item(V);
sp.QueryInterface(IWebBrowser2,ie);
if ie<>nil then
begin
if ie.LocationURL='http://www.sohu.com' then
begin
ie.Document.QueryInterface(IHTMLDocument2,idoc);
&n
模拟点击网页中的按钮
最新推荐文章于 2024-08-05 05:18:27 发布