Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server   Client   Old   Guides   Examples
New in version: 7.2   7.3   7.4   7.5   8.0   8.1   8.2   8.3   8.4   8.5    Statistic  

JSON.GetArrayItemsAsList

Queries a list of all array entries.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
JSON 4.2 Yes Yes Yes Yes Yes
MBS( "JSON.GetArrayItemsAsList"; json { ; ReturnValues } )   More

Parameters

Parameter Description Example value
json A JSON text or reference. "[1,2,3]"
ReturnValues Optional
Available in MBS FileMaker Plugin 8.1 or newer.
Pass 1 to return values instead of keeping strings in quotes.
1

Result

Returns list or error.

Description

Queries a list of all array entries.
Intended for arrays containing text or numbers.

Broken in version 6.0. Please use 6.1. Version 6.5 and newer doesn't add an extra newline any more.

Examples

Query a list from JSON array:

MBS( "JSON.GetArrayItemsAsList"; "[1,2,3]" )

Now a list of strings:

MBS( "JSON.GetArrayItemsAsList"; "[\"Hello\",\"World\",\"Test\"]" )

Now an array with objects:

MBS( "JSON.GetArrayItemsAsList"; "[\"Hello\", \"World\", {\"Hello\": \"test\"}]" )

See also

Created 18th August 2014, last changed 30th January 2018


JSON.GetArrayItem   -   JSON.GetArrayPathItems

Feedback: Report problem or ask question.




Links
MBS Xojo PDF Plugins