简体   繁体   English

ASP.NET:-Excel已下载但未显示数据

[英]ASP.NET :-Excel downloaded but not showing data

I am downloading excel from an application developed in ASP.NET and C#. 我正在从用ASP.NET和C#开发的应用程序中下载excel。 Its verified that data is coming in excel but when I click on file icon it is not showing data in excel. 它验证了数据来自excel,但是当我单击文件图标时,它不在excel中显示数据。

When I made some research,I found that Following steps resolved the issue. 经过研究,我发现遵循以下步骤可以解决该问题。 1 Right click on icon to view property of file and then click on unblock on property window. 1右键单击图标以查看文件的属性,然后在属性窗口上单击取消阻止。 2.Again , when I double click on file it is displaying data. 2.再次,当我双击文件时它正在显示数据。

Can Anyone ,Please help me to fix this issue using ASP.NET and C#. 任何人都可以,请帮助我使用ASP.NET和C#修复此问题。

new security settings from office. Office的新安全设置。 You can adjust setting in excel to allow downloaded files to be opened. 您可以在excel中调整设置以允许打开下载的文件。 But adjusting this setting is not recommanded because all evil downloaded macro's that you dont know about can run on your pc 但是不建议您调整此设置,因为您不知道的所有恶意下载宏都可以在您的PC上运行

  1. Open Excel 2013. 打开Excel 2013。
  2. Click on File > Options. 单击文件>选项。
  3. Select Trust Center > Trust center settings. 选择“信任中心”>“信任中心设置”。
  4. Select Protected view. 选择受保护的视图。
  5. Uncheck all the options under Protected View > OK. 取消选中“受保护的视图”>“确定”下的所有选项。
  6. Restart Excel 2010 and try to open Excel documents. 重新启动Excel 2010,然后尝试打开Excel文档。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM