编写翻译成功了,是到服务器的开拓IIS管理器

 

 专案中,需求实现用户上传Excel文件,很久此前,只兑现过Excel97-二零零四本子的文本,今后设想到用户有恐怕上传Excel二〇〇七或更高版本,七个本子连接有点不等同,可以参见http://www.cnblogs.com/insus/articles/2008946.html 使用.xlsx版本边接语句之后,在run先后时,即出现如下Error: 

The ‘Microsoft.Jet.OLEDB.4.0’ provider is not registered on the local
machine.

Server Error in ‘/WebSite1’ Application.


 

  今日装了六15人win7,编写翻译成功了,放在IIS里运营出错。The
‘Microsoft.Jet.OLEDB.4.0’ provider is not registered on the local
machine.
在此记录下来:

The ‘Microsoft.Jet.OLEDB.4.0’ provider is not registered on the local machine.

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.InvalidOperationException: The ‘Microsoft.Jet.OLEDB.4.0’
provider is not registered on the local machine.

Source Error:

The source code that generated this unhandled exception can only be shown when compiled in debug mode. To enable this, please follow one of the below steps, then request the URL:1. Add a "Debug=true" directive at the top of the file that generated the error. Example:<%@ Page Language="C#" Debug="true" %>or:2) Add the following section to the configuration file of your application:<configuration><system.web><compilation debug="true"/></system.web></configuration>Note that this second technique will cause all files within a given application to be compiled in debug mode. The first technique will cause only that particular file to be compiled in debug mode.Important: Running applications in debug mode does incur a memory/performance overhead. You should make sure that an application has debugging disabled before deploying into production scenario.

Stack Trace:

[InvalidOperationException: The 'Microsoft.Jet.OLEDB.4.0' provider is not registered on the local machine.]
   System.Data.OleDb.OleDbServicesWrapper.GetDataSource(OleDbConnectionString constr, DataSourceWrapper& datasrcWrapper) +1761342
   System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection) +1777302
   System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject) +100
   System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup) +43
   System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +6296143
   System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +6296606
   System.Data.OleDb.OleDbConnection.Open() +48
   System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +292
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +420
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +306
   System_HumanResources_KQ_Analysis.Data_Binding() +344
   System_HumanResources_KQ_Analysis.Page_Load(Object sender, EventArgs e) +247
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +25
   System.Web.UI.Control.LoadRecursive() +71
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3048

 


 

Version Information:
Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1

 

把程序放在windows 二零零六 PRADO2 64bit的服务器上,处理Excel时出现下边包车型地铁荒唐。

解决方法,是到服务器的打开IIS管理器。go to Application
Pool,找到呼应站点的池。右击Advanced setting… 参考下图,把Enable
32-Bit Application 设为由False 为True。

ca88亚洲城网站 1

 

Server Error in ‘/WebSite1’ Application.


The ‘Microsoft.Jet.OLEDB.4.0’ provider is not registered on the local
machine.
s

The ‘Microsoft.ACE.OLEDB.12.0’ provider is not registered on the local machine.

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.InvalidOperationException: The
‘Microsoft.ACE.OLEDB.12.0’ provider is not registered on the local
machine.

Source Error:

Line 21: 
Line 22: 

Line 23: objDa.Fill(objDs);

Line 24:         this.GridView1.DataSource = objDs.Tables[0];
Line 25:         this.GridView1.DataBind();

Source File:d:\ca88亚洲城网站,Projects\WebSite1\A.aspx.cs Line: 23

Stack Trace:

[InvalidOperationException: The 'Microsoft.ACE.OLEDB.12.0' provider is not registered on the local machine.]
   System.Data.OleDb.OleDbServicesWrapper.GetDataSource(OleDbConnectionString constr, DataSourceWrapper& datasrcWrapper) +1027372
   System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection) +337
   System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject) +86
   System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup) +31
   System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +76
   System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +126
   System.Data.OleDb.OleDbConnection.Open() +43
   System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +123
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) +319
   System.Data.Common.DbDataAdapter.Fill(DataSet dataSet) +94
   A.Page_Load(Object sender, EventArgs e) in d:\Projects\WebSite1\A.aspx.cs:23
   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
   System.Web.UI.Control.OnLoad(EventArgs e) +91
   System.Web.UI.Control.LoadRecursive() +74
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2207

 


Version Information:
Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.1

 

由来与化解办法,是因为web服务器并未设置 二〇〇七 Office System Driver: Data
Connectivity Components
,那么些组件有x86与x64版本,您能够依照实况选取性下载来安装。

下载连接:http://www.microsoft.com/downloads/en/details.aspx?FamilyID=c06b8369-60dd-4b64-a44b-84b371ede16d

 

以下内容于2017-03-23 23:07分添加:

也得以从下列连接实行下载并设置:
http://download.cnblogs.com/insus/Office/AccessDatabaseEngine.exe

 

在网上google了一晃,错误原因是自我的对讲机是64编写翻译的,需求改为33位,在vs中装置将编写翻译Any
CPU改为x86,就ok。

ca88亚洲城网站 2

相关文章