util.JSONArray.toString() produces a JSON string from the values included in the JSON array.
Syntax:
util.JSONArray.toString()
Usage and examples:
util.JSONArray.toString() creates a JSON string from the members of the JSON array.
example code #1 |
MAIN DEFINE json_arr util.JSONArray LET json_arr = util.JSONArray.create() CALL json_arr.put(1, 123) CALL json_arr.put(2, "abc") CALL json_arr.put(3, null) DISPLAY json_arr.toString() CALL fgl_getkey() END MAIN
|
example code #2 |
MAIN DEFINE json_arr util.JSONArray DEFINE da DYNAMIC ARRAY OF INTEGER LET json_arr = util.JSONArray.create() LET da[1] = 1 LET da[2] = 12 LET da[3] = 123 CALL json_arr.put(1, da) DISPLAY json_arr.toString() CALL fgl_getkey() END MAIN
|
obtained results |
Example programs:
CVS server: client.querix.com
CVS repository: /lycia_doc_examples
User: client
Project: auxiliary_features/json
Program: util_JSONArray_toString
Related articles: