Share via


ParserErrorCollection.Remove(ParserError) 方法

定義

從集合中移除指定的 ParserError 物件。

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

要從集合中移除的 ParserError

範例

下列程式碼範例示範如何從 物件中指定的 ParserErrorCollection 索引中移除 ParserError

// 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 時,請使用 方法從集合中移除 ParserError 物件。

適用於