Ive been trying to figure out an easy way to go from XML to List. Originally I wrote my program to use properties files like in JAVA to avoid XML but that lead to some restrictions later on.
Below is the XML file I am working with. What I would like to do is go to the <email> section and add every individual value for each <address> within <email> to a list object. I managed to get the list of values but in a single string of text that I would need to parse again, there has to be an easier way to get this to a list. I also tried looking online but I cant find an explanation on how to move from XML to list easily.
Code:<config> <settings> <configName></configName> <fileLocation></fileLocation> <exit></exit> </settings> <sendMail> <address></address> </sendMail> <email> <address></address> <address></address> <address></address> <address></address> </email> <ccemail> <address></address> <address></address> <address></address> <address></address> </ccemail> <keywords> <value></value> <value></value> <value></value> </keywords> </config>




Reply With Quote