resx: MissingManifestResourceException

I am currently developing an application that I know would be better if I support multi language. And while doing so encountered the above problem.


In your application (whatever it is web, mobile, desktop) take note of where you are saving the .resx file.

By this I mean the namespace, example:

You have an application HelloWorld, and you save the .resx file in the root directory.


So, when you access the resource you should call it by:

ResourceManager rm = new ResourceManager("HelloWorld.yourresource", System.Reflection.Assembly.GetExecutingAssembly());

This is for the default language, you will just have to create subdirectory for your locale example en-us, etc.
resx: MissingManifestResourceException resx: MissingManifestResourceException Reviewed by czetsuya on Thursday, September 10, 2009 Rating: 5

No comments:

Powered by Blogger.