ConfigurationElementCollection.BaseClear 方法    
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
从集合中移除所有配置元素对象。
protected:
 void BaseClear();
	protected public:
 void BaseClear();
	protected void BaseClear ();
	protected internal void BaseClear ();
	member this.BaseClear : unit -> unit
	Protected Sub BaseClear ()
	Protected Friend Sub BaseClear ()
	例外
示例
下面的代码示例演示如何调用 BaseClear 方法。
public void Remove(UrlConfigElement url)
{
    if (BaseIndexOf(url) >= 0)
    {
        BaseRemove(url.Name);
        // Your custom code goes here.
        Console.WriteLine("UrlsCollection: {0}", "Removed collection element!");
    }
}
Public Sub Remove(ByVal url As UrlConfigElement)
    If BaseIndexOf(url) >= 0 Then
        BaseRemove(url.Name)
        ' Your custom code goes here.
        Console.WriteLine("UrlsCollection: {0}", "Removed collection element!")
    End If
End Sub
	注解
              BaseClear调用 方法时,它会从集合中删除所有ConfigurationElement对象。 它还将 clear 指令插入配置文件。