Share via


DynamicJsonObject.TrySetMember Method

Sets the value of a DynamicJsonObject field using the specified name.

Namespace:  System.Web.Helpers
Assembly:  System.Web.Helpers (in System.Web.Helpers.dll)

Syntax

'Declaration
Public Overrides Function TrySetMember ( _
    binder As SetMemberBinder, _
    value As Object _
) As Boolean
'Usage
Dim instance As DynamicJsonObject 
Dim binder As SetMemberBinder 
Dim value As Object 
Dim returnValue As Boolean 

returnValue = instance.TrySetMember(binder, _
    value)
public override bool TrySetMember(
    SetMemberBinder binder,
    Object value
)
public:
virtual bool TrySetMember(
    SetMemberBinder^ binder, 
    Object^ value
) override
abstract TrySetMember : 
        binder:SetMemberBinder * 
        value:Object -> bool  
override TrySetMember : 
        binder:SetMemberBinder * 
        value:Object -> bool
public override function TrySetMember(
    binder : SetMemberBinder, 
    value : Object
) : boolean

Parameters

Return Value

Type: System.Boolean
true in all cases.

Remarks

If no field is found that has a name that matches the name that was specified by the binder parameter, a new field that has the specified name is created on the DynamicJsonObject instance and initialized to the specified value.

See Also

Reference

DynamicJsonObject Class

System.Web.Helpers Namespace