I remember reading once that .NET had a built in configSection handler that could handle a collection of key/value pairs without having to code my own custom classes. Similar to appSettings, but I can name the containing tag my own name and just start listing key/value pairs.
Anyone know if this exists and what it is called?
Example:
<configuration>
<configSections>
<section name="myKeys" type="Some.Built.In.Assembly, Some.Built.In.Assembly" />
</configSections>
<myKeys>
<add key="1" value="1" />
<add key="2" value="2" />
<add key="3" value="3" />
</myKeys>
What you are looking for is System.Configuration.NameValueFileSectionHandler. An example of its usage can be found here: 4guysfromrolla.com/articles/053102-1.aspx
(Edited the typo in the class name)