Please enable JavaScript to view this site.

InterFormNG Manual 2020

The ForEach element looks like this:

 

InterFormNG_ForEach_element_001

 

The ForEach element tells InterFormNG to run a DO-loop for all branches in the XML file with a specific name. With the ForEach Element you can e.g. do a loop for all detail ‘lines’ in the demo XML file. The properties are these:

 

InterFormNG_ForEach_element_002

 

The Xpath is the path to the branches that are to be handled. This is relative to the default cursor - alternatively it can be relative to another cursor - just state it under Cursor name.  

 

You can even use a condition inside the Xpath path to include only specific nodes. This path will for the Intro_demo.xml file only select two nodes:

/Root/Document[DocumentNo<=1003]

This means: Select all Document nodes, where the DocumenNo node is equal to or less than 1003.

 

For handling detail lines the ForEach element is normally inserted inside a flow area with a NewLine to separate each line.

 

Another similar loop element is the Repeat element.