先下载,再装入 在uses 里加上ShellAPI和UrlMonfunction DownLoadInternetFile(Source, Dest : String): Boolean; begin try Result := URLDownloadToFile(nil,PChar(Source),PChar(Dest),0,nil) = 0 except Result := False; end; end;procedure TForm1.Button1Click(Sender:TOBject); begin if DownLoadInternetFile('http://Url/PicFileName','c:\',0,nil) then if FileExists('你下载的文件') then Image1.Picture.LoadFrom..... end;
2.winexec('explorer www.sina.com.cn');
2、ShellExecute建议搜索一下,以前的帖子http://expert.csdn.net/Expert/TopicView1.asp?id=2280694
在uses 里加上ShellAPI和UrlMonfunction DownLoadInternetFile(Source, Dest : String): Boolean;
begin
try
Result := URLDownloadToFile(nil,PChar(Source),PChar(Dest),0,nil) = 0
except
Result := False;
end;
end;procedure TForm1.Button1Click(Sender:TOBject);
begin
if DownLoadInternetFile('http://Url/PicFileName','c:\',0,nil) then
if FileExists('你下载的文件') then
Image1.Picture.LoadFrom.....
end;