how to save all picture in mozilla active control
with twebbrowser i use this (but i want to use mozilla activex instead of ie and this nwork on max)
for k := 0 to wb.OleObject.Document.Images.Length - 1 do
begin
Source := Wb.OleObject.Document.Images.Item(k).Src;
n:=LastDelimiter('/', Source);
nom_ext:=Copy(Source, n + 1, Length(Source));
p := LastDelimiter('.', Source);
ext := Copy(Source, p + 1, Length(Source)); dest := ExtractFilePath(ParamStr(0)) + 'images\'+ nom_ext;
nom:=ChangeFileExt(nom_ext, ''); i:=0;
while FileExists(dest) do
begin
dest:=ExtractFilePath(ParamStr(0)) + 'images\'+
nom + inttostr(i) + '.' +ext;
inc(i);
end; DownloadFile(Source, dest);
end;function DownloadFile(SourceFile, DestFile: string): Boolean;
begin
try
Result := UrlDownloadToFile(nil, PChar(SourceFile), PChar(DestFile), 0,
nil) = 0;
except
Result := False;
end;
end;
--Using Opera's revolutionary e-mail client: http://www.opera.com/mail/ _______________________________________________ mozilla-embedding mailing list [email protected] http://mail.mozilla.org/listinfo/mozilla-embedding
