Execution Flow Control - WorkView - Foundation 24.1 - Foundation 24.1 - Ready - OnBase - Premier - external - Premier

WorkView

Platform
OnBase
Product
WorkView
Release
Foundation 24.1
License
Premier

Break

Defines a block to be executed when the value of the named data address changes while iterating a data loop. The data must be sorted in such a way that the control break makes sense. An iterative loop may contain multiple control breaks, added from highest to lowest level. Each control break block can contain a header block and/or a footer block; at least one of these must be included. Example:

<<Filter:Issues - All Issues-Original>>

<<Break:Buyer>>

<<Header>>

<<!—Add code here -->>

<<End>>

<<Footer>>

<<!—Add code here -->>

<<End>>

<<End>>

<<Break:Status>>

<<Footer>>

<<!—Add code here -->>

<<End>>

<<End>>

<<End>>

CreateNamedBlock

Defines a template block that is not executed inline, but rather later called and executed by name. This can be used for template sections that might have utility in more than one location in the master template, or for long and complex template sections, allowing better organization. Example:

<<CreateNamedBlock: MainBodyTemplate>>

<<End>>

ExecuteNamedBlock

Find a template block previously created using CreateNamedBlock and execute the template section within. Example:

<<ExecuteNamedBlock: MainBodyTemplate>>

DoWhile

Executes a template block in a looping fashion, testing the provided condition each iteration. As long as the test condition is true, the loop will continue to repeat. Example:

<<DoWhile: #_count < 100 >>

<<End>>

Footer

Defines a template block that is to function as a total or final section of a larger template block, usually used in the context of a control break section (See Break in Execution Work Flow).

Header

Defines a template block that is to function as a heading or first-time-only section of a larger template block. Usually used in the context of a control break section but can also be used within a filter type template block (See Break in Execution Work Flow).

If

The execution of the contained template block is controlled by the condition specified. If the condition evaluates to TRUE, the template block is executed. If the condition evaluates to FALSE, the block is skipped. It can, optionally, be associated with an ELSE block where, if FALSE and the ELSE block exists, it is executed. Example:

<<If: @AdditionalStreetAddress = “”>>

<<End>>

<<Else>>

<<End>>

Else

See the If description.

Loop

Executes the contained template block for the specified number of times. Loop count can be a fixed numeric literal, a variable name, or an attribute name. Example:

<<Loop: 100>>

<<End>>

Totals

A template block section that is executed at the end of an iteration block, executed once and only after all iterations of the parent block have executed. If the iterating parent block has no results to process, totals are NOT performed. Accumulators and item count can be referenced in this block to obtain grand totals for all item resulting from the iteration. Example:

<<Totals>>

<<End>>

Switch

A structure that allows for the testing of a data value against a set of expected values much like the similar C++ and C# statements. The first condition to match determines which block is executed. If none of the conditions is matched the default case, if one is specified, is execute. If no default case is provided and no other case matches, execution falls through and no output results. An example is best to illustrate this:

<<Switch: @Quantity>>

<<Case: > 500>>

<<Set: Label = "501-600">>

<<End>>

<<Case: > 400>>

<<Set: Label = "401-500">>

<<End>>

<<Case: > 300>>

<<Set: Label = "301-400">>

<<End>>

<<Case: > 200>>

<<Set: Label = "201-300">>

<<End>>

<<Case: > 100>>

<<Set: Label = "101-200">>

<<End>>

<<Case: > 50>>

<<Set: Label = "51-100">>

<<End>>

<<Case: > 25>>

<<Set: Label = " 26-50">>

<<End>>

<<Default>>

<<Set: Label = " 1-25">>

<<End>>

<<End>>