ParserErrorCollection.Remove(ParserError) 方法

定义

从集合中移除指定的 ParserError 对象。Removes the specified ParserError object from the collection.

public:
 void Remove(System::Web::ParserError ^ value);
public void Remove (System.Web.ParserError value);
member this.Remove : System.Web.ParserError -> unit
Public Sub Remove (value As ParserError)

参数

value
ParserError

要从该集合中移除的 ParserErrorThe ParserError to remove from the collection.

示例

下面的代码示例演示如何 ParserError 从对象中的指定索引处删除 ParserErrorCollectionThe following code example demonstrates how to remove a ParserError from the specified index in a ParserErrorCollection object.

// Insert a ParserError at index 0 of the collection.
ParserError error = new ParserError("Error", "Path", 1);
collection.Insert(0, error);

// Remove the specified ParserError from the collection.
collection.Remove(error);
' Insert a ParserError at index 0 of the collection.
Dim [error] As New ParserError("Error", "Path", 1)
collection.Insert(0, [error])

' Remove the specified ParserError from the collection.
collection.Remove([error])

注解

Remove ParserError 当具有对的引用时,请使用方法从集合中删除对象 ParserErrorUse the Remove method to remove a ParserError object from the collection when you have a reference to the ParserError.

适用于