新闻建站cms系统、政府cms系统定制开发

广州网站建设公司-阅速公司

asp.net新闻发布系统、报纸数字报系统方案
/
http://www.ysneo.com/
广州网站建设公司
您当前位置:首页>网站技术

网站技术

No Entity Framework provider found for the ADO.NET provider

发布时间:2014/2/21 16:23:32  作者:Admin  阅读:2771  

广告:阿里云采购优惠专区

Server Error in '/' Application.

--------------------------------------------------------------------------------

No Entity Framework provider found for the ADO.NET provider with invariant name 'System.Data.SqlClient'. Make sure the provider is registered in the 'entityFramework' section of the application config file. See http://go.microsoft.com/fwlink/?LinkId=260882 for more information.

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: No Entity Framework provider found for the ADO.NET provider with invariant name 'System.Data.SqlClient'. Make sure the provider is registered in the 'entityFramework' section of the application config file. See http://go.microsoft.com/fwlink/?LinkId=260882 for more information.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

 

[InvalidOperationException: No Entity Framework provider found for the ADO.NET provider with invariant name 'System.Data.SqlClient'. Make sure the provider is registered in the 'entityFramework' section of the application config file. See http://go.microsoft.com/fwlink/?LinkId=260882 for more information.]

System.Data.Entity.Infrastructure.DependencyResolution.DefaultProviderServicesResolver.GetService(Type type, Object key) +71

System.Data.Entity.Infrastructure.DependencyResolution.<>c__DisplayClass1.<GetService>b__0(Tuple`2 k) +23

System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory) +72

System.Data.Entity.Infrastructure.DependencyResolution.CachingDependencyResolver.GetService(Type type, Object key) +140

System.Data.Entity.Infrastructure.DependencyResolution.<>c__DisplayClass3.<GetService>b__0(IDbDependencyResolver r) +19

System.Linq.WhereSelectArrayIterator`2.MoveNext() +85

System.Linq.Enumerable.FirstOrDefault(IEnumerable`1 source, Func`2 predicate) +166

System.Data.Entity.Infrastructure.DependencyResolution.ResolverChain.GetService(Type type, Object key) +162

System.Data.Entity.Infrastructure.DependencyResolution.RootDependencyResolver.GetService(Type type, Object key) +46

System.Data.Entity.Infrastructure.DependencyResolution.<>c__DisplayClass3.<GetService>b__0(IDbDependencyResolver r) +19

System.Linq.WhereSelectArrayIterator`2.MoveNext() +85

System.Linq.Enumerable.FirstOrDefault(IEnumerable`1 source, Func`2 predicate) +99

System.Data.Entity.Infrastructure.DependencyResolution.ResolverChain.GetService(Type type, Object key) +162

System.Data.Entity.Infrastructure.DependencyResolution.CompositeResolver`2.GetService(Type type, Object key) +65

System.Data.Entity.Infrastructure.DependencyResolution.DbDependencyResolverExtensions.GetService(IDbDependencyResolver resolver, Object key) +93

System.Data.Entity.Utilities.DbProviderFactoryExtensions.GetProviderServices(DbProviderFactory factory) +131

System.Data.Entity.Infrastructure.<>c__DisplayClass1.<ResolveManifestToken>b__0(Tuple`3 k) +21

System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory) +72

System.Data.Entity.Infrastructure.DefaultManifestTokenResolver.ResolveManifestToken(DbConnection connection) +180

System.Data.Entity.Utilities.DbConnectionExtensions.GetProviderInfo(DbConnection connection, DbProviderManifest& providerManifest) +56

System.Data.Entity.DbModelBuilder.Build(DbConnection providerConnection) +43

System.Data.Entity.Internal.LazyInternalContext.CreateModel(LazyInternalContext internalContext) +62

System.Data.Entity.Internal.RetryLazy`2.GetValue(TInput input) +117

System.Data.Entity.Internal.LazyInternalContext.InitializeContext() +592

System.Data.Entity.Internal.InternalContext.GetEntitySetAndBaseTypeForType(Type entityType) +18

System.Data.Entity.Internal.Linq.InternalSet`1.Initialize() +57

System.Data.Entity.Internal.Linq.InternalSet`1.GetEnumerator() +15

System.Data.Entity.Infrastructure.DbQuery`1.System.Collections.Generic.IEnumerable<TResult>.GetEnumerator() +53

System.Linq.WhereEnumerableIterator`1.MoveNext() +63

System.Collections.Generic.List`1..ctor(IEnumerable`1 collection) +327

System.Linq.Enumerable.ToList(IEnumerable`1 source) +58

TopWin.Etone.Infrastructure.Framework.RepositoryBase`1.GetMany(Func`2 where) in D:\yunyou2\Yunyou_N\TopWin.Etone.Infrastructure\Framework\RepositoryBase.cs:123

TopWin.Etone.Data.UserRepository.FindByUserName(String UserName) in D:\yunyou2\Yunyou_N\TopWin.Etone.Data\Infrastructure\UserRepository.cs:32

TopWin.Etone.Web.Controllers.AccountController.Login(LoginModel LoginModel) in D:\yunyou2\Yunyou_N\TopWin.Etone.Web\Controllers\AccountController.cs:57

lambda_method(Closure , ControllerBase , Object[] ) +108

System.Web.Mvc.ActionMethodDispatcher.Execute(ControllerBase controller, Object[] parameters) +17

System.Web.Mvc.ReflectedActionDescriptor.Execute(ControllerContext controllerContext, IDictionary`2 parameters) +208

System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters) +27

System.Web.Mvc.<>c__DisplayClass15.<InvokeActionMethodWithFilters>b__12() +55

System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodFilter(IActionFilter filter, ActionExecutingContext preContext, Func`1 continuation) +263

System.Web.Mvc.<>c__DisplayClass17.<InvokeActionMethodWithFilters>b__14() +19

System.Web.Mvc.ControllerActionInvoker.InvokeActionMethodWithFilters(ControllerContext controllerContext, IList`1 filters, ActionDescriptor actionDescriptor, IDictionary`2 parameters) +191

System.Web.Mvc.ControllerActionInvoker.InvokeAction(ControllerContext controllerContext, String actionName) +343

System.Web.Mvc.Controller.ExecuteCore() +116

System.Web.Mvc.ControllerBase.Execute(RequestContext requestContext) +97

System.Web.Mvc.ControllerBase.System.Web.Mvc.IController.Execute(RequestContext requestContext) +10

System.Web.Mvc.<>c__DisplayClassb.<BeginProcessRequest>b__5() +37

System.Web.Mvc.Async.<>c__DisplayClass1.<MakeVoidDelegate>b__0() +21

System.Web.Mvc.Async.<>c__DisplayClass8`1.<BeginSynchronous>b__7(IAsyncResult _) +12

System.Web.Mvc.Async.WrappedAsyncResult`1.End() +62

System.Web.Mvc.<>c__DisplayClasse.<EndProcessRequest>b__d() +50

System.Web.Mvc.SecurityUtil.<GetCallInAppTrustThunk>b__0(Action f) +7

System.Web.Mvc.SecurityUtil.ProcessInApplicationTrust(Action action) +22

System.Web.Mvc.MvcHandler.EndProcessRequest(IAsyncResult asyncResult) +60

System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) +9

System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +8836977

System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +184

 

 

--------------------------------------------------------------------------------

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

 

解决办法:

1.

Install-Package EntityFramework

PM> Install-Package EntityFramework -Version 6.0.2

Install-Package Npgsql -Pre

Install-Package EntityFramework -Pre (表示最新)

Uninstall-Package EntityFramework -Version 6.1.0-beta1

2. 项目中包含EntityFramework.SqlServer.dll和 EntityFramework.SqlServer.xml 然后再发布即可

 

 

广告:阿里云新人采购专场

相关文章
EntityFramework
Install
cms新闻系统购买咨询
扫描关注 广州阅速软件科技有限公司
扫描关注 广州阅速科技