“客户不拥有所需的权限”使用 ExcelPackage 时出错

发布于 2024-08-08 20:36:26 字数 614 浏览 2 评论 0原文

我正在使用 ExcelPackage 通过.net 创建 Excel 工作表。

我正在 codeplex< 获取参考/a> 用于创建 Excel 工作表。

它给了我以下错误:

A required privilege is not held by the client. 

在创建 FileInfo 类对象时的行处,

FileInfo newFile = new FileInfo(@"C:\mynewfile.xlsx");

标题为错误“IOException 未由用户代码处理”。

如何解决呢?请帮助....

问候 吉里什

I am using ExcelPackage to create the excel sheet through .net.

I am taking the reference at codeplex for creating excel sheet.

It is giving me following error:

A required privilege is not held by the client. 

at the line when creating object of FileInfo class as

FileInfo newFile = new FileInfo(@"C:\mynewfile.xlsx");

with the heading of Error "IOException was unhandled by user code."

How to resolve it ? Please help ....

Regards
Girish

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

暮光沉寂 2024-08-15 20:36:26

我在生产环境中使用 ExcelPackage 并且没有遇到任何问题。请将文件夹所需的权限授予经过身份验证的用户或进程运行所在的用户帐户(aspnet?)。

I'm using ExcelPackage in production environment and haven't got into any problem. Please give required permissions to on the folder to authenticated users or the user account (aspnet?) under which the process is running.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文