I have a MVC website which is using .resx
files for localization. However, the current behavior for determining which localizations are supported requires iterating over the physical .resx
files, and they don't exist once the site has been compiled for publishing.
The folder structure is currently:
- Language Resources
- Resource.en-US.resx
- Resource.fr-CA.resx
- Resource.hi.resx
- Resource.resx
Trying to get the list of all the resource files via GetManifestResourceNames()
, as per this answer, only produces the single LanguageResources.Resource.resources
file that represents the master, unlocalized list. It may or may not have the localizations embedded into it, but there's no way I've found to see that.
How can I tell at runtime that I support three languages?
The end goal is to build a dropdown based on these three values. If there's another way I should be approaching this problem, answers which address that are also acceptable.