Adds a JSON child element of type String to an existing JSON object.
JSON is a lightweight data exchange format. It is described
at http://json.org. It is based on the Javascript
language.
The JSON Objects used in Seminar Pro contain a collection of
key-value pairs.
(The internal JSON
object is of Xojo type JSONItem [classic
Xojo framework])
Parameters:
Name |
Type |
Description |
jsnHandle |
Integer |
A
pointer to the created JSON object, of type Integer Is 0
or higher, if JSON object exists |
key |
String |
The exact
name of the key for which its value will be set. |
value |
String |
The
text to be attributed to the key. |
Available in:
WindowMain |
WindowLink |
YES |
YES |
Used in:
XojoScript
Name |
GUID |
Send
Seminar Invoice by Email |
024F872B-9E87-499F-9D2D-208C4C32E4CF |
Hint: You can
find references to XojoScripts which make use of this function by sending the
following SQL statement to the database:
Select id,GUID, ScriptName,ScriptCode from
im_scripts where ScriptCode Like '%JsonSetValue%'
Example XojoScript:
Dim
handle As Integer
= JsonCreate
If
handle >= 0 Then
JsonSetValue(handle,"subject","title")
JsonSetValue(handle,"content","bodytext")
JsonSetValue(handle,"recipientemail","support@seminar.pro")
Dim js As String = JsonToString(handle)
//
{"subject":"title","content":"bodytext","recipientemail":"support@seminar.pro"}
MsgBox(js)
End
If