Wenn dann MSHTML_EWB da es eine EmbeddedWB Komponente is.
Jetzt habe ich einen prozedur: dort erkennt er jedoch das .Document nicht -.-
Delphi-Quellcode:
procedure WB_FillPwdForm(WB: EmbeddedWB; UsernameField, User, PasswortField, Password: string);
var
IDoc3: IHTMLDocument3;
Inputs: IHTMLElementCollection;
UID, UPWD: IHTMLElement;
begin
if Assigned(WB.Document) and
(Succeeded(WB.Document.QueryInterface(IHTMLDocument3, IDoc3))) then
begin
Inputs := IDoc3.getElementsByName(UsernameField);
if Assigned(Inputs) then
begin
UID := Inputs.item(0, '') as IHTMLElement;
if Assigned(UID) then
(UID as IHTMLInputElement).value := User;
end;
Inputs := IDoc3.getElementsByName(PasswortField);
if Assigned(Inputs) then
begin
UPWD := Inputs.item(0, '') as IHTMLElement;
if Assigned(UPWD) then
(UPWD as IHTMLInputElement).value := Password;
end;
end;
end;