Share via


ModelStateDictionary.SetModelValue Method

Sets the value for the specified key by using the specified value provider dictionary.

Namespace:  System.Web.Http.ModelBinding
Assembly:  System.Web.Http (in System.Web.Http.dll)

Syntax

'Declaration
Public Sub SetModelValue ( _
    key As String, _
    value As ValueProviderResult _
)
'Usage
Dim instance As ModelStateDictionary
Dim key As String
Dim value As ValueProviderResult

instance.SetModelValue(key, value)
public void SetModelValue(
    string key,
    ValueProviderResult value
)
public:
void SetModelValue(
    String^ key, 
    ValueProviderResult^ value
)
member SetModelValue : 
        key:string * 
        value:ValueProviderResult -> unit 
public function SetModelValue(
    key : String, 
    value : ValueProviderResult
)

Parameters

See Also

Reference

ModelStateDictionary Class

System.Web.Http.ModelBinding Namespace