Access to the path Denied when uploading excel file

耗尽温柔 提交于 2019-11-29 15:47:52

Make sure the folder C:\Data\IronElements\Upload\AUMData has NTFS write permission for the user in which context IIS executes. Also please make sure that the subfolders of C:\Data\IronElements\Upload inherits permissions from it's parent. To do this, click Advanced button from security tab -> Change permissions -> check Replace all child object permissions with inheritable permissions from this object -> Hit Ok

The account that your web session is running under does not have permissions to write to that folder. Once you give the ASP.Net account (or whichever account you are using) the required permissions, it should work as expected.

go to the app-pool which you are using for this application and change the identity of it to 'Network Service'. I faced the similar issue and fixed in same way

To get a better handle on permission problems like this I always create a low-priv'ed user to run our websites. The user is named after the website itself so it's obvious what it's for.

Then that user only gets perms on the right folders, in your case, C:\Data\IronElements\Upload\AUMData. It's also a good way to limit DB access - create a login for that specific user in SQL with minimal privs.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!