Last post May 22, 2006 09:28 AM by ArchMystic
May 18, 2006 08:18 AM|ArchMystic|LINK
I'm trying to implement a multi-language solution into a website. Currently the website will only be in Dutch. More languages will follow in the future.
protected void Page_Init(object sender,
resourceManager = (ResourceManager)Application["resourceManager"];
In App_GlobalResources I've created _Resource.nl-NL.resx which I compile into Resource.nl-NL.resources. Most of the time it runs fine, but sometimes I get the following
An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Resources.MissingManifestResourceException: Could not find any resources appropriate for the specified culture (or the neutral culture) on disk.
baseName: Resource locationInfo: <null> fileName: Resource.resources
Creating Resource.resources doesn't fix the problem. The error is still shown.
Does anyone know what I'm doing wrong here?
May 22, 2006 05:26 AM|YongKang|LINK
Please help to clarify:
When the error occurred, how to resolve the problem? Reboot IIS server? Reset IIS service? Or simply access the same page again?
You can also download FileMon to monitor resource access behavior when the problem occurred again:
May 22, 2006 09:28 AM|ArchMystic|LINK
The error occurs after editing the web.config file or a .cs file. After editing these files .Net 2.0 buils on the first load, right? The same procedure (editing web.config or a .cs file) solves the problem.
So after building, the ResourceManager gets the culture, or it doesn't. It seems pretty much random.
Accessing the resources doesn't seem to be the problem. Understanding the culture is.