ResourceManager.GetString() unsafe
C#
1
Posts
1
Posters
0
Views
1
Watching
-
I prepare my application for L10N and use System.Resources.ResourceManager.GetString() to retrieve string resources. Works great, but does not include any compile-time checking: The argument to GetString() is an alphanumeric string identifier. A typo in this ID, and the application will still compile. Only when the string is needed (probably to display crucial details of that critical error), if cannot be found and GetString() returns null. This is not good. Does anybody know of any tools or preferences that validate the presence of required string resources at compile-time? TIA, Bernd :confused: