If you want to store configuration information in a XML file, you can easily use serialization to assist you. Instead of using XPath or DOM, and have some code to maintain, simply use the XmlSerializer to retrieve information.
Here's an example of a XML file:
And if you have the following classes (C#):
All you have to do to load the XML information into the DatabaseConfig class is (C#):
DatabaseConfig
There are a few issues you have to handle when using XML Serialization, wich you can see at my earlier posts about XML, XSD and Serialization.
Disclaimer The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.