Every time I edited a C# file in my solution, I had an error called “Could not find any resources appropriate for the specified culture or the neutral culture. Make sure "UI.Web.Mvc.Properties.Resources.resources" was correctly embedded or linked into assembly "UI.Web.Mvc" at compile time, or that all the satellite assemblies required are loadable and fully signed.”. The error said that the Resource file wasn’t setup correctly. The strange thing about it that my colleagues didn’t got the error and when I cleaned up the web application mvc project and builded the project again, the site worked correctly. Cleaning and building after each edit is a huge consuming of you time so I needed a fix for this.
After searching for some time I found the difference between my laptop and the laptops of my colleagues. They had the Dutch version of Windows 7 Enterprise and I had the English version. The project is by default Dutch and we are still developing so in the solution we only had the Dutch version of the resource file. When I ran my project, the culture is set to the host and after that, it looks to the culture of the browser. My host is English so I couldn’t find any English resource. Why It worked correctly after a clean, I don’t know. Can you tell me?
I fixed the error by adding the English version of the resource file. Just copied the Dutch version and added “en” to the name. Simple fix, big irritations and a hope useless time… It’s now time to hurry up and finish the baby :-)