I have a resource file called suggestions.xml
which is translated to a couple of languages. These XML files contain just <string>
values.
Now, I'd like to retrieve all the strings in the current locale's suggestions.xml
file. How do I do that? I know I can retrieve single strings by their ID's, but I'd like to get all the strings in the XML file instead.
You can declare your strings like this.
In your activity class, you can access them like the following.
Just store your Local Strings in an
Array
in yoursuggestions.xml
file.