Scilab Website | Contribute with GitLab | Mailing list archives | ATOMS toolboxes
Scilab Online Help
2025.0.0 - Français


fromJSON

Convert JSON to scilab variable.

Syntax

result = fromJSON(jsonData)
result = fromJSON(jsonFilename, "file")

Arguments

jsonData
A string containing JSON data.

jsonFilename
Path and name of the file containing input JSON data.

result
If the string is a correct JSON, result contain the scilab variable.

Description

This function convert string or JSON files into a Scilab variable.

Examples

fromJSON("{status: OK, value:12}")
fromJSON("[1, 2, 3]")
fromJSON("{test:[a, b], values:[1, 2]")

See also

History

VersionDescription
6.1 Function introduced.
2023.0.0 Handling of tabs (ascii(9)) changed.
Report an issue
<< Outils web Outils web http_delete >>

Copyright (c) 2022-2024 (Dassault Systèmes)
Copyright (c) 2017-2022 (ESI Group)
Copyright (c) 2011-2017 (Scilab Enterprises)
Copyright (c) 1989-2012 (INRIA)
Copyright (c) 1989-2007 (ENPC)
with contributors
Last updated:
Thu Oct 24 11:16:04 CEST 2024