User GuideReference ManualIntegration Scenarios
 

1.5.7. XML Printer Message Format

See: Managing Channels - Manage a Channel

						XML Printer Wizard screen allows you to use any document printed using the virtual printer driver
						xmlprinter
						as message in.
					

The xmlprinter is a printer driver generating a xml file containing all the visual information of the document. The text elements are part of that document. So it is possible to "parse the document" to extract an other xml document, more usable in EDI exchanges. xmlprinter provides a tool called the composer to create such parsers definition.

Note that Babelway and xmlprinter are note affiliated. We do not provide any garantie on the xmlprinter but the tool has demonstrated to be very useful when no other extract method is easy to setup or when the output is a PDF enriched whith the data as attachment.

Getting started with xmlprinter

  • download the printer driver VERSION xmlprinter35.3512.exe from http://www.xmlprinter.com/file/xmlprinter35-3512-exe and follow the instruction for download and licensing.
  • install the driver. The administration is web based and available in http://127.0.0.1:57823/settings. Set the "Output directory" according your preferences.
  • go to you application and print an example of the document you want to exchange. You have now in the "Output directory" the "printed xml" document.

Add a parser step and send it to Babelway

  • Open the Xml Printer Composer and load the printed xml.
  • Create your structure by mapping visual elements. Use tutorial at http://www.xmlprinter.com/support/parser . This is not so easy but I got it working quite nicely. Tips: don't be afraid to edit the definition xml manually and relead it in the Composer.
  • Configure a "parse" processing step using your newly created definition
  • Add a second "execute" processing step linked to a batch to send the file in ftp of ftps. Here is an simple example:
    ;@echo off
    ;(for /f "usebackq delims=" %%A in ("%~f0") do call echo.%%A)>"%temp%\%~n0.ftp"
    ;ftp -i -s:"%temp%\%~n0.ftp"
    ;GOTO:EOF

    open ftp.babelway.net
    your_ftp_user
    your_ftp_password
    !:--- FTP commands below here ---
    cd /
    binary
    put %1
    disconnect
    bye

Wizard screen

When you create a new message format, you must first configure it using the following wizard.

XML Printer Wizard screen

Figure 1.45. XML Printer Wizard screen


An XML Printer messsage is set up using the xml printer definition file (created with the composer) and a sample of the printed output in XML. For both files, select the files using the Browse... button next to the Xml Printer definition and Xml Printer sample output, then click on the Upload command.

Edit screen

Once the files have been uploaded, or when it is used or copied from a saved format, edit screen appears as follows.

XML Edit screen

Figure 1.46. XML Edit screen


See Message Edit Functions for further information on message definition, contextual menu and additional commands available on this screen.

See Unwrapping an Incoming Message for more details on the options available to receive message in zip format containing both a PDF and the XML output.