ConfigurationElementCollection.BaseRemoveAt(Int32) 方法

定义

移除位于指定索引位置的 ConfigurationElementRemoves the ConfigurationElement at the specified index location.

protected:
 void BaseRemoveAt(int index);
protected public:
 void BaseRemoveAt(int index);
protected void BaseRemoveAt (int index);
protected internal void BaseRemoveAt (int index);
member this.BaseRemoveAt : int -> unit
Protected Sub BaseRemoveAt (index As Integer)
Protected Friend Sub BaseRemoveAt (index As Integer)

参数

index
Int32

要移除的 ConfigurationElement 的索引位置。The index location of the ConfigurationElement to remove.

例外

配置是只读的。The configuration is read-only.

- 或 --or- index 小于 0 或大于集合中的 ConfigurationElement 对象数。index is less than 0 or greater than the number of ConfigurationElement objects in the collection.

- 或 --or- ConfigurationElement 对象已移除。The ConfigurationElement object has already been removed.

- 或 --or- ConfigurationElement 对象的值已在更高级别锁定。The value of the ConfigurationElement object has been locked at a higher level.

- 或 --or- ConfigurationElement 对象被继承。The ConfigurationElement object was inherited.

- 或 --or- ConfigurationElement 对象的 Type 的值不是 AddRemoveClearMapAddRemoveClearMapAlternateThe value of the ConfigurationElement object's Type is not AddRemoveClearMap or AddRemoveClearMapAlternate.

注解

BaseRemoveAt方法将指令插入 <remove> 到指定索引位置处的元素的配置文件中。The BaseRemoveAt method inserts a <remove> directive into the configuration file for the element at the specified index location.

适用于