• If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Announcement

Collapse
No announcement yet.

vvOut a internal DS

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • vvOut a internal DS

    is there an easy way to send a multi-occurence DataStructure which has multiple subfields in it? For example, using vvOut_xxx or sth, instead of building the complete JSON string myself.

    The following 2 ways in vvOut_toJSON has limitations:

    By specifying vvOut.object, it only works if the DS is vvTreeDS or refers to a external defined file.

    or

    By specifying vvOut.fieldxxxxx, it only works with an array (which contain only 1 field).


    Thanks,
    Dan
    Last edited by Dan; 06-08-2011, 03:20 PM. Reason: more detail

  • #2
    Hi Dan -

    Could you elaborate a little further on this? Are you attempting to send a multi-dimensional array to the front-end (arrays within arrays) or do you want to send multiple "roots" at the same time?

    Comment


    • #3
      Hello, Sean.

      I want to be able to send out a json response similar to what you can do to send out multiple records in a physical file using vvOut_toJSON. Difference is: the data won't be from a physical file, but from an "Array Data Structure" (defined in the program NOT using "LIKEREC", and loaded at run time).


      Thanks,
      Dan
      Last edited by Dan; 06-09-2011, 10:22 AM.

      Comment


      • #4
        In that case, you would need to build the JSON string yourself. You could use vvOut_buffer to build the string within your program as this will store everything until you are ready to send it out.

        Comment

        Working...
        X