⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 systemsettingssection.cs

📁 Microsoft Mobile Development Handbook的代码,有C#,VB,C++的
💻 CS
字号:
using System;
using Microsoft.Practices.Mobile.Configuration;

namespace MobileDevelopersHandbook
{
    public class SystemSettingsItemElement : ConfigurationElement
    {
        [ConfigurationProperty("Name", IsRequired = true)]
        public String Name
        {
            get { return (String)this["Name"]; }
        }

        [ConfigurationProperty("Value", IsRequired = true)]
        public String Value
        {
            get { return (String)this["Value"]; }
        }
    }

    public class SystemSettingsItemElementCollection : ConfigurationElementCollection
    {
        protected override ConfigurationElement CreateNewElement()
        {
            return new SystemSettingsItemElement();
        }

        protected override Object GetElementKey(ConfigurationElement element)
        {
            SystemSettingsItemElement e = (SystemSettingsItemElement)element;
            return e.Name;
        }
    }

    public class SystemSettingsSection : ConfigurationSection
    {
        [ConfigurationProperty("SystemSettingsItems")]
        public SystemSettingsItemElementCollection SystemSettingsItems
        {
            get
            {
                return (SystemSettingsItemElementCollection)(this["SystemSettingsItems"]);
            }
        }
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -