System.Resources.MissingManifestResourceException当更新数据库 [英] System.Resources.MissingManifestResourceException when Updating database

查看:744
本文介绍了System.Resources.MissingManifestResourceException当更新数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我搬到一个Web应用程序,我从一台机器工作到另一个。它使用的.Net MVC和Entity Framework构建,但是当我执行更新,数据库命令,以便更新数据库,我得到这个错误:

I moved a web application I am working on from one machine to another. It is built using .Net MVC and Entity Framework but when I execute the Update-Database command so that the database is updated, I get this error:

Could not find any resources appropriate for the specified culture or the neutral culture.  Make sure "NameofMigration.resources" was correctly embedded or linked into assembly "NameofProject" at compile time, or that all the satellite assemblies required are loadable and fully signed.

有谁知道如何解决这个问题?

Does anyone know how to fix this error?

推荐答案

我有一个类似的问题时,在项目文件未包含迁移的RESX一部分,当一个家伙开发商检查项目(可能是由于合并问题)。您可能会发现RESX文件是有,但灰色。如果它的存在,试着右击NameofMigration.resx文件并选择包括项目。如果它不存在,你最好去找到它的另一台计算机上,并将其添加到项目中: - )

I had a similar issue when the resx part of the migration was not included in the project file when a fellow developer checked the project in (probably due to a merge issue). You may find that the resx file is there but greyed out. If it's there, try right clicking the "NameofMigration.resx" file and selecting "include in project". If it's not there, you better go find it on the other machine and add it to the project :-)

这篇关于System.Resources.MissingManifestResourceException当更新数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆