Skip to content

Best way to store ArrayList in terms of Application Configuration?

Neal

Asked Apr 3, 2007, 12:40 AM EDT2 answers
Share
LinkedInX

Hi

I'm looking for an idea for the best way to store an ArrayList that's part of the Application Configuration. The ArrayList will store the list of languages the Application supports plus a description of each, so values will be for example:
"en" "English"
"de" "German"
"es" "Spanish"

I'm looking to build in a combobox which will allow the User to select the language for the UI, the different languages will be stored in .resx files.

2 Answers

Know the answer? Post it. Somebody with the same question will find it here.

  • Mahesh Chand
    0
    I would create a class with members you want to store and build an ArrayList of that class type. I would put all resources in an XML file and fill the ArrayList from the XML file. It will give you flexibility to add and remove more items without recompiling the application.
    0
  • 0
    Thanks Mahesh, seems a better approach alright!
    0