读书人

IdHttp.Get获取文件,该怎么解决

发布时间: 2012-02-06 15:52:44 作者: rapoo

IdHttp.Get获取文件

Delphi(Pascal) code
    if FileExists('.\Images\' + FilePath + '\' + FileName) then        tStream := TFileStream.Create('.\Images\' + FilePath + '\' + FileName,fmOpenWrite)    else        tStream := TFileStream.Create('.\Images\' + FilePath + '\' + FileName,fmCreate);  try    IdHttp.Get(URL + FileName,tStream);    tStream.Free  except    tStream.Free ;    DeleteFile('.\Images\' + FilePath + '\' + FileName) ;  end;


不知道啥原因,能够获取到pdf文件及jpg文件,但是在获取dwg后缀的文件就报错。

HTTP/1.1 404 not found

[解决办法]
找不到,确认路径,用其他软件能否下载?
[解决办法]
文件找不到

读书人网 >.NET

热点推荐