uses UrlMon ; function DownLoadInternetFile(Source, Dest : String) : Boolean; begin try Result := URLDownloadToFile(nil,PChar(Source),PChar(Dest),0,nil) = 0 except Result := False; end; end;
保存为Tsream,然后显示: procedure TForm1.Button1Click(Sender: TObject); var tm: TMemoryStream; begin try tm := TMemoryStream.Create; IdHTTP1.Get(''''http://delphi.ktop.com.tw/delphi.gif'''', tm); ShowMessage(''''OK''''); finally tm.Free; end; end;