0

在我的机器上一切正常,但是在发布到 godaddy 后,我收到了这个错误:

 [5/28/2014 3:54:41 AM ]: The 'Microsoft.ACE.OLEDB.12.0' provider is not registered on the local machine. , System.Data ,   at System.Data.OleDb.OleDbServicesWrapper.GetDataSource(OleDbConnectionString constr, DataSourceWrapper& datasrcWrapper)
   at System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection)
   at System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject)
   at System.Data.ProviderBase.DbConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.ProviderBase.DbConnectionInternal.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
   at System.Data.OleDb.OleDbConnection.Open()
   at LinqToExcel.Query.ExcelUtilities.GetWorksheetNames(ExcelQueryArgs args)
   at LinqToExcel.Query.ExcelQueryExecutor.GetWorksheetName()
   at LinqToExcel.Query.ExcelQueryExecutor..ctor(ExcelQueryArgs args)
   at LinqToExcel.Query.ExcelQueryable`1..ctor(ExcelQueryArgs args)
   at LinqToExcel.ExcelQueryFactory.Worksheet(Int32 worksheetIndex)
   at ArabicEWorld.BusinessLayer.NounManager.processNounFile(String path)
   at ArabicEWorld.WebService.ArabicEWorldWebService.ProcessNounsFile() , 

知道如何使它在托管服务器上正常工作,它也是共享主机,我的意思是我无法在其上设置任何程序。

4

2 回答 2

1

就像评论中提到的 Krishanu Dey 一样,您不能在 GoDaddy 的共享主机上使用 LinqToExcel,因为他们不会让您安装 LinqToExcel 使用的所需 OleDb 引擎。

您需要考虑获得一个 VPS 来安装 OleDeb 引擎。

于 2014-05-28T13:22:25.650 回答
0

我使用 openxml SDK 解决了它,速度有点慢,但它完成了任务

于 2014-05-29T11:52:59.377 回答