Syntax 

JsonMember


Group 

Miscellaneous 


Description 

A JsonMember object is returned when a JsonValues object containing a JSON object is indexed by numerical index.


  • JsonMember.Name
    This is the name of the member in the JSON object.
     
  • JsonMember[.Value]
    Get the value of the JsonMember. This is the default property.


JSON

Type Returned by Value

null

Variant (Null value)

false

Boolean

true

Boolean

number

Double

"..."

String

[...]

JsonValues (the returned JsonValues's HasMemberNames is False)

{...}

JsonValues (the returned JsonValues's HasMemberNames is True)


See Also 

JsonValues, ParseJson( )


Example

Sub Main

    Dim text As String

    text = "{""member1"":""value1""}"

    Dim json As JsonValues

    Set json = ParseJson(text)

    Dim jsonmember As JsonMember

    Set jsonmember = json(0)

    Debug.Print jsonmember.name '"member1

    Debug.Print jsonmember.value '"value1"

    Debug.Print jsonmember '"value1"

    Debug.Print IsEmpty(json(1)) 'True

End Sub