Flatten To JSON Function
- Updated2025-07-30
- 2 minute(s) read
Converts data you wire to the anything input to a UTF-8 JavaScript Object Notation (JSON) string.

Inputs/Outputs
enable LabVIEW extensions? (T)
—
enable LabVIEW extensions enables LabVIEW JSON extensions to support NaN and Inf values of floating-point numbers. Not all JSON parsers support these extensions.
anything
—
anything contains the data you want to convert to a UTF-8 JSON string. This input accepts arrays and clusters of Booleans, floating-point numbers, and strings. anything can also accept an array of clusters, or a cluster of arrays, of these data types. This input does not support other data types, such as enums, refnums, file paths, and fixed-point numbers. Cluster elements may be named or unnamed, but not a combination of both. If cluster elements are named, then each name must be unique to that cluster. If you wire an unsupported data type, LabVIEW breaks the VI.
error in (no error)
—
error in describes error conditions that occur before this node runs. This input provides standard error in functionality.
JSON string
—
JSON string is the flattened data encoded in UTF-8. UTF-8 encoded strings may not display correctly in LabVIEW controls.
error out
—
error out contains error information. This output provides standard error out functionality. |
enable LabVIEW extensions? (T)
—
anything
—
error in (no error)
—
JSON string
—
error out
—