iNTERFACEWARE Products Manual > Learning Center > Tutorials and Sample Scenarios > Working With Other Message Formats > Generating HL7 Version 3 Messages > Creating a VMD File To Generate HL7 Version 3 Messages |
|
Looking for Iguana v.5 or v.6? Learn More or see the Help Center.
Now that you have the VMD file that generates the XML text, the next step is to create a VMD file to generate the HL7 version 3 message. This step is not that complicated, as this VMD file calls an external Python module to perform the conversion. (This module is described in Loading the Python Module Into Iguana.) To create this VMD file:
This code is required because Chameleon expects all messages to start with an MSH segment, whereas the messages this VMD file will be receiving have been converted to XML data by the other VMD file.
This code calls the hl7version3() Python function, which does the actual conversion work. It is passed value[3:] as an argument because the Global Inbound Script added MSH to the value variable. value[3:] removes the first three characters - the MSH characters - from value before passing it to hl7version3().
|