How to include simple collections in ConfigurationSection

Posted by mikemanne on Stack Overflow See other posts from Stack Overflow or by mikemanne
Published on 2010-04-23T13:49:07Z Indexed on 2010/04/23 13:53 UTC
Read the original article Hit count: 317

Is there a way for me to include a simple array of strings, or List<string> on my custom subclass of ConfigurationSection? (Or an array or generic list of simple data objects, for that matter?)

I'm becoming familiar with the new (and VERY verbose) ConfigurationSection, ConfigurationElement, and ConfigurationElementCollection classes, but I'm by no means an expert yet.

It seems like ConfigurationSection should handle simple collections/lists on its own, without me having to create a custom ConfigurationElementCollection subclass for each and every one. But I haven't found any reference to this ability online.

© Stack Overflow or respective owner

Related posts about .NET

Related posts about configuration