Go to previous topic
Go to next topic
Last Post 10/11/2019 10:14 AM by  Steph76
XML Node parse and assign
 2 Replies
Author Messages
Steph76
Solution Developer
Private
Basic Member
(35 points)
Basic Member
Posts:15


Send Message:

--
10/11/2019 8:54 AM

    Hello,

    I need to create a PF to update the date fields for a job. I have a Lawson Transaction Node to Inquire on the job and an XML Node to parse the output from it so I can get the current settings. I do not have an XSD. I noticed some of the fields have a dash in the name and I'm having a problem when trying to assign the value to a variable. Fields without a dash return a value. For example, XML9300_output.AR580[0].COMPANY, returns the Company. When trying to get the process level using XML9300_output.AR580[0].PROCESS-LEVEL, nothing is returned. I've tried the following different ways to get the value and I either get nothing or "error evaluating". Has anyone else run into this?

     

    XML9300_output.AR580[0].["PROCESS-LEVEL"] - error on node error evaluating

    XML9300_output.AR580[0]."PROCESS-LEVEL" - error on node error evaluating

     

    ** Lawson V10, IPD Product Version: 10.1.1.30.4710

    David Williams
    Private
    Private
    Veteran Member
    (3223 points)
    Veteran Member
    Posts:1085


    Send Message:

    --
    10/11/2019 9:00 AM
    Replace the dash - with an underscore _
    David Williams
    Steph76
    Solution Developer
    Private
    Basic Member
    (35 points)
    Basic Member
    Posts:15


    Send Message:

    --
    10/11/2019 10:14 AM

     

    Thanks. I was overcomplicating it. I didn't need the XML Node.



    ---