Convert XML to Associative Array
Associative Arrays in BrightScript are so much easier to work with in comparison to working with XML elements, which is why I like to convert XML to AA.
Once converted to Associative Array, saving to JSON is just as easy with FormatJSON().
BrightScript code can be found here
https://github.com/brightscripters/brs_xml2aa
Converting from JSON or from Associative Array to XML might come in handy too.
Stay tuned...