Right-clicking the Contexts node
To create a context by adding it in the Rules window:
- In the Rules window, right-click one of the three Contexts nodes.
- In the pop-up window, click Add.
The Build RefName dialog box appears. Note that when you open the dialog box, the Path is partially filled in. The contents of the Path box depend on the amount of information that is known based on the context type of the new context. Similarly, the contents of the list box vary based on the context type.
For example, the following figure illustrates the Build RefName dialog box for Generic Form context. Specify the path starting with the form name.
- For each component of the RefName path, select the component from the list in the dialog box.
- Click Next, or, to backtrack to a previous component, click Back.
The InForm Architect application builds the path from your selections and displays it in the Path field at the top of the dialog box.
- When the RefName path is complete, click Done.
The InForm Architect application inserts the path into the component definition you are creating. The RefName and Arguments dialog box opens, enabling you to specify the RefName of the context and the values of the context-specific arguments.
- In the RefName and Arguments dialog box, optionally give the context a new Context RefName.
Note: If you do not specify a new Context RefName, the InForm Architect application creates a Context RefName by appending the visit number to the RefName of the rule.
To create a Context RefName from the RefName path of the context item:
- Select the Value cell of the Context RefName.
- Click the Build RefName button.
- In the Build RefName dialog box, create a RefName path as described in Using the Build RefName tool. Specify whether you want to separate components of the RefName path with underscores or initial capital letters by selecting the Underscored or Capitalized option.
- If you want the arguments to have context-specific values, specify those values.
Note: If you do not change the default value of an argument, the InForm Architect application does not add a new argument to the context, and the rule uses the default argument values when it runs in this context.
Optionally, to specify a RefName path as the value of a string type argument:
- Select the Value cell of the argument.
- Click the Build RefName button.
- In the Build RefName dialog box, create a RefName path as described in Using the Build RefName tool.
- When the RefName path is complete, click Done.
- In the RefName and Arguments dialog box, click OK.
The Rule window shows the addition of the new context.
- Define the remaining properties of the context by editing its properties in the Properties window. The following table describes all of the properties that make up a context definition.
Property
Description
Context RefName
RefName of the component.
REQUIRED.
For rules about the use of RefNames, see RefNames
Context Help Text
Description of the edit check being performed in this context. This text is displayed along with CRF Help for the item against which the rule runs. If you define context-specific help text, it overrides the default text specified in the Help Text property for the rule.
OPTIONAL.
Context Event
RefName of the event that is triggered when the rule runs in this context. Select one event from the list of defined events. The event determines the default text of a query generated if the rule fails. An event defined for a context overrides the event specified as the default for the rule.
OPTIONAL.