Foxtable(狐表)用户栏目专家坐堂 → [讨论]FTPClient的Upload方法无法上传只读文件?


  共有2171人关注过本帖平板打印复制链接

主题:[讨论]FTPClient的Upload方法无法上传只读文件?

帅哥哟,离线,有人找我吗?
jspta
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:七尾狐 帖子:1731 积分:11255 威望:0 精华:0 注册:2011/12/15 22:06:00
[讨论]FTPClient的Upload方法无法上传只读文件?  发帖心情 Post By:2015/8/24 10:44:00 [只看该作者]

FTPClient的Upload方法无法上传只读文件?怎么解决?

---------------------------
版本:2014.11.11.1
---------------------------
代码执行出错,错误信息:



System.UnauthorizedAccessException: 对路径“XXX”的访问被拒绝。

   在 System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)

   在 System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy)

   在 System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, String msgPath, Boolean bFromProxy)

   在 System.IO.FileStream..ctor(String path, FileMode mode)

   在 Foxtable.FTPClient.O__0O_o0(String A_0, String A_1, Boolean A_2)

   在 Foxtable.FTPClient.oO_o_o0_(String A_0, Boolean A_1)

   在 Foxtable.FTPClient.Upload(String fileName)

   在 UserCode.Test()
---------------------------
确定   
---------------------------


 回到顶部