ConfigurationElement.Item[String] 属性

定义

获取或设置此 ConfigurationElement 对象的属性 (Property)、属性 (Attribute) 或子元素。Gets or sets a property, attribute, or child element of this ConfigurationElement object.

重载

Item[ConfigurationProperty]

获取或设置此配置元素的属性或特性。Gets or sets a property or attribute of this configuration element.

Item[String]

获取或设置此配置元素的属性、特性或子元素。Gets or sets a property, attribute, or child element of this configuration element.

注解

使用此方法可获取或设置 @no__t 0 对象的值。Use this method to get or set the values of a ConfigurationProperty object.

Item[ConfigurationProperty]

获取或设置此配置元素的属性或特性。Gets or sets a property or attribute of this configuration element.

protected public:
 property System::Object ^ default[System::Configuration::ConfigurationProperty ^] { System::Object ^ get(System::Configuration::ConfigurationProperty ^ property); void set(System::Configuration::ConfigurationProperty ^ property, System::Object ^ value); };
protected internal object this[System.Configuration.ConfigurationProperty property] { get; set; }
member this.Item(System.Configuration.ConfigurationProperty) : obj with get, set
Default Protected Friend Property Item(property As ConfigurationProperty) As Object

参数

prop
ConfigurationProperty

要访问的属性。The property to access.

属性值

指定的属性、特性或子元素。The specified property, attribute, or child element.

异常

propnull 或不存在于元素中。prop is null or does not exist within the element.

prop 为只读或被锁定。prop is read only or locked.

注解

使用 Item[String] 属性可获取或设置 @no__t 对象的值。Use the Item[String] property to get or set the values of a ConfigurationProperty object.

在 C# 中,此属性是 ConfigurationSectionCollection 类的索引器。In C#, this property is the indexer for the ConfigurationSectionCollection class.

Item[String]

获取或设置此配置元素的属性、特性或子元素。Gets or sets a property, attribute, or child element of this configuration element.

protected public:
 property System::Object ^ default[System::String ^] { System::Object ^ get(System::String ^ property_name); void set(System::String ^ property_name, System::Object ^ value); };
protected internal object this[string property_name] { get; set; }
member this.Item(string) : obj with get, set
Default Protected Friend Property Item(property_name As String) As Object

参数

propertyName
String

要访问的 ConfigurationProperty 的名称。The name of the ConfigurationProperty to access.

属性值

指定的属性、特性或子元素。The specified property, attribute, or child element

异常

prop 为只读或被锁定。prop is read-only or locked.

注解

使用 Item[String] 属性可获取或设置 @no__t 对象的值。Use the Item[String] property to get or set the values of a ConfigurationProperty object.

在 C# 中,此属性是 ConfigurationSectionCollection 类的索引器。In C#, this property is the indexer for the ConfigurationSectionCollection class.

适用于