private static Section GetSettings(Item item, Section globalSection, string name)
{
foreach (Item childItem in item.Children)
{
string pathName = name + "." + childItem.Name;
if (childItem.TemplateName.Equals("Folder"))
{
GetSettings(childItem, globalSection, pathName);
}
else
{
globalSection.Add(new Setting(pathName, childItem.Fields["Value"].ToString(), typeof(string)));
}
}
return globalSection;
}
}