我目前正在使用 Visual Studio 2010 并创建了一个“ASP.NET MVC 3 Web 应用程序”。
由于 Darin 指出的原因,我已将问题从 SQLite 更改为 MySQL。
所以我设置了我的 MySQL 数据库并配置了 web.config,如 this answer 所示。 ,但是我得到即时配置错误:
Parser Error Message: Could not load file or assembly 'MySql.Web, Version=6.2.2.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The system cannot find the file specified.
Line 78: type="MySql.Web.Security.MySQLRoleProvider, MySql.Web
这是因为公钥不对吗?
谢谢
最佳答案
您需要编写一个与 SQLite 一起使用的自定义成员资格提供程序。这是一个 example with MySQL .另请注意,SQLite 不适用于 ASP.NET 等多线程环境。
关于.net - 使用 ASP.NET MVC 3 设置 MySQL,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5192596/