Announcement

Collapse
No announcement yet.

Msg object contains XML tag

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

  • Msg object contains XML tag

    Code:
    var myXmlString = responseMap.get('Previous Destination').getMessage();
    
    channelMap.put("Response From Previous", myXmlString);
    
    msg = SerializerFactory.getHL7Serializer(false, false, true).toXML(myXmlString );
    
    channelMap.put("here is the message so far", msg );

    When I try to iterate through the msg, I get this error:
    Code:
    TypeError: <?xml version="1.0" encoding="UTF-8"?><HL7Message><MSH>
    Does anyone have any hints on how to load the XML properly into the msg object?

  • #2
    try
    Code:
    msg = new XML(SerializerFactory.getHL7Serializer(false, false, true).toXML(myXmlString ));
    Daniel Svanstedt
    Software Engineer
    Mirth Corporation

    Want professional services, support, and enterprise or virtual appliances? It's all available from the Mirth Corporation:
    Mirth Support | Mirth Training | Mirth Appliances | Online Training | Developer Q&A

    Don't forget, Mirth Support gives you access to all of our online training videos, and silver support gives you access to developer Q&As!

    Comment


    • #3
      Dan, this worked just as I needed.

      Thanks for your help, much appreciated!

      Comment

      Working...
      X