GetArraySize
![GetArraySize 1:](Images/jpg/13439170443__Web.jpg)
This method returns the number of elements in a JSON array.
Syntax
METHOD GetArraySize : UDINT
VAR_INPUT
v : SJsonValue;
END_VAR
Return value
Name | Type |
---|---|
GetArraySize | UDINT |
Inputs
Name | Type |
---|---|
v | SJsonValue |
Sample call:
jsonDoc := fbJson.ParseDocument(sExistingJsonDocument);
jsonArray := fbJson.FindMember(jsonDoc, 'array');
nSize := fbJson.GetArraySize(jsonArray);