User Manual

GETTING STARTED


MODULES AND PLATFORM


APPENDIX


TUTORIALS & HELPFUL TRICKS


STRATEGIC PARTNER LINKS

Sepasoft - MES Modules
Cirrus Link - MQTT Modules

RESOURCES

Inductive University
Ignition Demo Project
Knowledge Base Articles
Forum
IA Support
SDK Documentation
SDK Examples

ALL USER MANUAL VERSIONS

Ignition 8.1
Ignition 7.9
Ignition 7.8

Deprecated Pages

Employees

Sign In

Skip to end of metadata
Go to start of metadata

This function is used by Ignition's Expression language.

Description

Takes a JSON friendly string, a path string, and value, and will return a new JSON friendly string with the provided path set to the provided value. This is best used in conjunction with the Derived Tags writeback value.

Syntax

 jsonSet(json, path, value)

  • Parameters

string json - The JSON string. The string must be in a JSON friendly format.

string path - The path string.

object value - The replacement for the value at the path.

  • Results

string - A JSON friendly string with a new value set at the specified path.

Examples
Code Snippet
// This example takes a JSON friendly string and sets the provided path to the given value. This would then return the string {'item':{'firstThing':1, 'secondThing':5}}

jsonSet("{'item':{'firstThing':1, 'secondThing':2}}", "item.secondThing", 5)
  • No labels