Sorry, formatting messed up and I can't seem to edit... If your message class is the one you want to convert just extend both XML and JSON ? Extends (%Persistent, %XML.Adaptor, %JSON.Adaptor) And (assuming your schemas line up): Set tSC = tMsg.%JSONExportToString(.tJSONMsg)
If your message class is the one you want to convert just extend both XML and JSON ? Extends (%Persistent, %XML.Adaptor, %JSON.Adaptor) And (assuming your schemas line up): Set tSC = tMsg.%JSONExportToString(.tJSONMsg)
Certifications & Credly badges:
Neil has no Certifications & Credly badges yet.
Global Masters badges:
Followers:
Neil has no followers yet.
Following:
Neil has not followed anybody yet.
At this point in your code - Do base64.Rewind() - base64 isn't a stream object because of how you've populated it earlier in the DTL.
I'm guessing
target.{PIDgrpgrp(1).ORCgrp(1).OBXgrp(1).OBX:5(1).5} returns a string so you need to write that into the Stream:
base64.Write({PIDgrpgrp(1).ORCgrp(1).OBXgrp(1).OBX:5(1).5})
before you call your custom function (assuming you've already instantiated your stream).