Topics   All   Mac OS X (Only)   Windows (Only)   Linux (Only, Not)   iOS (Only, Not)  
Components   Crossplatform Mac & Win   Server (Not)   Client   Old   Guides   Examples
New in version: 6.3   6.4   6.5   7.0   7.1   7.2   7.3   7.4   7.5   8.0    Statistic  

JSON.Format

Returns pretty printed JSON for the given JSON text.

Component Version macOS Windows Server FileMaker Cloud FileMaker iOS SDK
JSON 4.4 Yes Yes Yes Yes Yes

MBS( "JSON.Format"; json )

Parameters

Parameter Description Example value
json A JSON text or reference. "[1,2,3]"

Result

Returns JSON code.

Description

Returns pretty printed JSON for the given JSON text.

Examples

Format some object:

Set Variable [$json; Value:MBS( "JSON.Format"; "{\"Hello\": \"World\"}" )]
Show Custom Dialog [$json]

Parse some JSON, display it formatted and release:

Set Variable [$json; Value:MBS( "JSON.Parse"; "{\"Hello\": \"World\"}" )]
Show Custom Dialog [$json; MBS("JSON.Format"; $json)]
Set Variable [$r; Value:MBS( "JSON.Release"; $json)]

See also

Example Databases


JSON.DeleteItemFromObject   -   JSON.GetArrayItem

Feedback: Report problem or ask question.




Links
MBS Xojo PDF Plugins