2013-07-17 95 views
0

我试图弄清楚这一点了几天了,我有我的项目的自定义成员资格和角色提供程序,它在我的开发机器上完美工作,但在生产它抛出在web.config中的以下错误mvc3在Web.Config上的自定义角色提供程序错误

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Exception has been thrown by the target of an invocation.

Source Error:

Line 24: <providers> 
Line 25:   <clear /> 
Line 26:   <add name="FeelSafeRoleProvider" type="FeelSafe.Helpers.FeelSafeRoleProvider, FeelSafe" connectionStringName="FeelSafeEntities" /> 
Line 27:  </providers> 
Line 28:  </roleManager> 

Source File: (...)\web.config Line: 26

我读过关于有simmilar问题的人,因为他们没有命名他们的ConnectionStrings但我的ConnectionString定义如下

<connectionStrings> 
<add name="FeelSafeEntities" connectionString="metadata=res://*/Models.FeelSafe.csdl|res://*/Models.FeelSafe.ssdl|res://*/Models.FeelSafe.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=PLESK-23\SQLEXPRESS;Initial Catalog=FeelSafe;Persist Security Info=True;User ID={user};Password={password};MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" /> 
</connectionStrings> 

这是怎么回事? 如果您需要更多的信息,只需询问,我会提供。

感谢您的帮助

回答

0

OK,发现该问题并不直接与角色提供程序类,也不ConnectionString,则MySQL的连接器的版本是旧的,更新它解决了这个错误。

相关问题