Developing ASP.NET MVC Web Applications — Question 103
You are designing a localized ASP.NET application to support multiple cultures.
You need to ensure that the application can be displayed in several languages.
How should you implement this feature?
Answer options
- A. Use a resource (.resx) file.
- B. Include language-specific content in the assembly manifest.
- C. Use Systems.Collections.Generics.Dictionary to store alternative translations.
- D. Ensure that all strings aremarked internal.
Correct answer: A
Explanation
The correct answer is A, as resource (.resx) files are specifically designed for localizing .NET applications by storing culture-specific strings. Option B is incorrect because the assembly manifest does not support language-specific content directly. Option C is not ideal for localization since a Dictionary does not provide the same structured support for multiple cultures as .resx files. Option D is irrelevant to localization, as marking strings internal does not aid in presenting multiple languages.