Output From Row Project
To follow along with the guide please download the project files: Rowout Example Project Files
For an explanation of Project D click here Row Output: Project D
For an explanation of Project C click here Row Output: Project C
NOTE: The “Split String” function is only in version 11.01.10 and after for eFORMz.
This guide is about how to handle XML input that has multiple XML tags which loop more than once. What does it mean for XML input tag to loop more than once? It simply means that the XML tag does not define a set number of times it will be placed into the XML document. It could be 1-n items. Here is an example of XML with multiple XML tags that loop more than once. The XML tags POs, PODETAIL1, SKU, and QTY are all examples of an XML tag that loops more than once in this instance. In this example, it’s important to print out the SKUs and QTYs underneath their respective POs (PO1 and PO2).
<Data> <POs> <PONBR>PO1</PONBR> <PODETAIL1><SKU>SKU01</SKU><QTY>2</QTY></PODETAIL1> <PODETAIL1><SKU>SKU02</SKU><QTY>21</QTY></PODETAIL1> </POs> <POs> <PONBR>PO2</PONBR> <PODETAIL1><SKU>SKUB01</SKU><QTY>2</QTY></PODETAIL1> <PODETAIL1><SKU>SKUB02</SKU><QTY>21</QTY></PODETAIL1> </POs> </Data>
The document template in eFORMz can only iterate through one XML tag that loops. Notice how inside of the POs XML tag there are more looping XML tags inside of it, such as SKU and QTY. If you would like to see what happens when you don’t call another project to grab the SKU’s and QTY please active “Row: Item Detail”, deactivate “Row output from project” and “Row: Call ProjectC” in ProjectD.
In order to grab the SKU and QTY underneath each of its respective POs, we must call another Project. In our case we will use Row output from project.