我用这方法
procedure Tform1.DoWithHtmlElement(aElementCollection:IHTMLElementCollection);
var
k:integer;
vk
leVariant;
Dispatch: IDispatch;
HTMLInputElement:IHTMLInputElement;
HTMLSelectElement:IHTMLSelectElement;
HTMLOptionElement: IHTMLOptionElement;
HTMLTextAreaElement: IHTMLTextAreaElement;
HTMLFormElement:IHTMLFormElement;
HTMLImgElement:IHTMLImgElement;
HTMLOptionButtonElement:IHTMLOptionButtonElement;
begin
for k:=0 to aElementCollection.length -1 do
begin
Vk:=k;
Application.ProcessMessages;
Dispatch:=aElementCollection.item(Vk,0);
if Succeeded(Dispatch.QueryInterface(IHTMLInputElement,HTMLInputElement)) then
begin
With HTMLInputElement do//单行文本
begin
{ if (UpperCase(Type_)='TEXT') or (UpperCase(Type_)='PASSWORD') then
begin
memo1.Lines.Add('单行文本'+name+'-----------------------'+value);
{ if UpperCase(name)='LOGINCODE' then value:=username;
{ if UpperCase(name)='PASSWORD'then value:='9805104';
memo1.Lines.Add('单行文本'+name+'-----------------------'); }
if UpperCase(Type_)='TEXT' then
begin
if UpperCase(name)=UpperCase(edit4.Text) then value:=edit2.Text ;
end
else if UpperCase(Type_)='PASSWORD' then
begin
memo1.Lines.Add('单行文本'+name+'-----------------------');
if UpperCase(name)=UpperCase(edit5.Text) then value:=edit3.Text ;
end
else if (UpperCase(Type_)='CHECKBOX') then//复选框
begin
checked:=true;
memo1.Lines.Add('复选框'+name);
end
else if (UpperCase(Type_)='RADIO') then//单选框
begin
checked :=true;
memo1.Lines.Add('单选框'+name);
end;
end;
end
else if SUCCEEDED(Dispatch.QueryInterface(IHTMLImgElement,HTMLImgElement))then
begin
with HTMLImgElement do//表单
begin
savetoimg(HTMLImgElement);
//处理
memo1.Lines.Add('图片'+name);
end;
取得IMG的,我就想就这方法取出图片,有办法吗
介绍个HTMXXXXXXXXX的帮助给我看看吧
或加我QQ吧,我的天!!!!