上载Excel工作表时出错

问题描述:



当我将代码上传到在线导入Excel工作表时出现错误.代码在数据库和前端位于同一台计算机上的开发端上正确运行.但是,当我将此代码上传到在线并单击导入按钮,然后显示错误.

描述:当前Web请求的执行期间发生未处理的异常.请查看堆栈跟踪,以获取有关错误及其在代码中起源的更多信息.

异常详细信息:System.Data.OleDb.OleDbException:没有可用的错误消息,结果代码:E_FAIL(0x80004005).


为此请帮帮我.
谢谢您.

Hi,

There is an error when I upload my code to online for import excel sheet. Code is properly run on devlopment end in which database and frontend is in same machine. But when I upload this code to online and click on import button then display error .

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Data.OleDb.OleDbException: No error message available, result code: E_FAIL(0x80004005).


Please help me out for this.
Thanking you

确保xl文件位于bin文件夹中.否则,请尝试在连接字符串中提供xl文件的绝对路径.

检查天气,您是否具有用于访问Excel文件的有效身份验证
Make sure that the xl file exists in the bin folder. Otherwise, try giving absolute path of the xl file in the connection string.
Or
Check weather do you have valid authentication for accessing excel file