-
If
action=hide
,
the associated option is not defined. If
action=show
,
the associated option is defined and appears in the SAS code that
is generated by the Velocity script.
-
Not all dependencies are evaluated
each time the Velocity script runs and produces the SAS code. When
the task is first opened, all dependencies are run to establish initial
values. After that, only dependencies that are linked to the current
interaction in the user interface are evaluated. The value of the
condition
attribute
determines whether a dependency is evaluated.
-
Dependencies are evaluated in top-down
order.
-
An option is order independent
if the option name appears only in the
condition
attribute
of the
Target
element.
-
An option is order dependent if
the option name appears in both the
condition
and
option
attributes
of the
Target
element.
This example shows a
correct and incorrect ordering of dependencies:
<UI>
<Container option="options">
<Group option="basic options">
<Option name="COMBOBOX"/>
<Option name="ITEM1"/>
<Option name="ITEM2"/>
<Option name="ITEM3"/>
<OptionItem option="CHECKBOX"/>
<OptionItem option="INPUTTEXT"/>
</Group>
</Container>
</UI>
<Dependencies>
1<!-- Correct ordering of the dependencies -->
<Dependency condition="$COMBOBOX=='ITEM1'">
<Target conditionResult="true" option="CHECKBOX" action="set"
property="value" value="1"/>
</Dependency>
<Dependency condition="$CHECKBOX=='1'">
<Target conditionResult="true" option="INPUTTEXT" action="enable"/>
<Target conditionResult="false" option="INPUTTEXT" action="disable"/>
</Dependency>
2<!-- Incorrect ordering to the dependencies -->
<Dependency condition="$CHECKBOX=='1'">
<Target conditionResult="true" option="INPUTTEXT" action="enable"/>
<Target conditionResult="false" option="INPUTTEXT" action="disable"/>
</Dependency>
<Dependency condition="$COMBOBOX=='ITEM1'">
<Target conditionResult="true" option="CHECKBOX" action="set"
property="value" value="1"/>
</Dependency>
</Dependencies>
1 |
This
first dependency is order independent. COMBOBOX is a name that is
used in the condition, but the value of COMBOBOX is not a target in
any of the other dependencies.
|
2 |
The
second dependency is order dependent. CHECKBOX is used in the condition,
and the value of CHECKBOX is also a target for option=”CHECKBOX” in
the preceding Dependency element. In this
case, the state for INPUTTEXT is not evaluated properly because condition=”$CHECKBOX=='1'" is
evaluated before condition=”$COMBOBOX=='ITEM1'" .
|