问题描述
没有为ADO.NET提供程序找到具有不变名称System.Data.SqlClient的实体框架提供程序。确保提供程序已在应用程序配置文件的entityFramework部分中注册。
有关详细信息,请参阅http://go.microsoft.com/fwlink/?LinkId=260882。 />
Iam使用EntityFrameWork并且插入记录时出错
我的项目是4层
我尝试过:
在BLL Layer App.Config:
< configuration>
< configsections>
<! - 有关Entity Framework配置的更多信息,请访问http://go.microsoft .com / fwlink /?LinkID = 237468 - >
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."
Iam Using EntityFrameWork And This Is Error When Insert Record
My Project Is 4-Layer
What I have tried:
In BLL Layer App.Config :
<configuration>
<configsections>
<!-- For more information on Entity Framework configuration, visit http://go.microsoft.com/fwlink/?LinkID=237468 -->
推荐答案
Try adding the following runtime assembly bindings:
< runtime>
< assemblyBinding xmlns =urn:schemas -microsoft-com:asm.v1>
< dependentAssembly>
< assemblyIdentity name =EntityFrameworkpublicKeyToken =b77a5c561934e089culture =neutral/ >
< bindingRedirect oldVersion =0.0.0.0-6.0.0.0newVersion =6.0.0.0/>
< / dependentAssembly>
< / assemblyBinding>
< / runtime>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="EntityFramework" publicKeyToken="b77a5c561934e089" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
这篇关于错误:没有为ADO.NET找到实体框架提供程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!