ModelStateDictionary.Remove ModelStateDictionary.Remove ModelStateDictionary.Remove Method

Definition

Overloads

Remove(KeyValuePair<String,ModelState>) Remove(KeyValuePair<String,ModelState>) Remove(KeyValuePair<String,ModelState>)

Removes the first occurrence of the specified item from the model-state dictionary.

Remove(String) Remove(String) Remove(String)

Removes the item that has the specified key from the model-state dictionary.

Remove(KeyValuePair<String,ModelState>) Remove(KeyValuePair<String,ModelState>) Remove(KeyValuePair<String,ModelState>)

Removes the first occurrence of the specified item from the model-state dictionary.

public bool Remove (System.Collections.Generic.KeyValuePair<string,System.Web.WebPages.Html.ModelState> item);
abstract member Remove : System.Collections.Generic.KeyValuePair<string, System.Web.WebPages.Html.ModelState> -> bool
override this.Remove : System.Collections.Generic.KeyValuePair<string, System.Web.WebPages.Html.ModelState> -> bool
Public Function Remove (item As KeyValuePair(Of String, ModelState)) As Boolean
Parameters
item
KeyValuePair<String,ModelState>

The item to remove.

Returns

true if the item was successfully removed from the model-state dictionary; false if the item was not removed or if the item does not exist in the model-state dictionary.

Remove(String) Remove(String) Remove(String)

Removes the item that has the specified key from the model-state dictionary.

public bool Remove (string key);
abstract member Remove : string -> bool
override this.Remove : string -> bool
Public Function Remove (key As String) As Boolean
Parameters
key
String String String

The key of the element to remove.

Returns

true if the item was successfully removed from the model-state dictionary; false if the item was not removed or does not exist in the model-state dictionary.

Applies to