Lists entries expected in a field.

The Choice extraction rule turns a one-character field whose expected content belongs to a fixed list (for example Y=Yes, N=No) into an XML element of choice type (combo box or radio buttons) with a predefined list of actions.
Note: XML elements of the choice type are handled by the choice XSL template described in the choice.xsl file. To change the way choices are displayed in the HTML page, edit this file.

Property Type Category Description
Action label separators String configuration When extracting actions from the screen, defines the character(s) separating a label from the corresponding action value (if applicable).

For example, if the list of choices is (Y=Yes, N=No), the action label separator is “=”.
This property is used only if actions are extracted from screen (Options from screen property set to true).
Actions XMLVector configuration Defines the actions table listing possible actions.
The Actions table is a two-column table:

Label: defines the action label to be displayed in the combo box (for example “Yes”),
Command: defines the action value to be sent in the field (for example “Y”).

Notes:

• A new action can be added to the list using the blue keyboard icon. The HTTP headers defined in the list can be ordered using the arrow up and arrow down buttons, or deleted using the red cross icon.
• This property is used only if actions are not extracted from screen (Options from screen property set to false).
Actions separators String configuration When extracting actions from the screen, defines the character(s) separating actions from each others (if applicable).

For example, if the list of choices is (Y=Yes, N=No), the actions separator is “,”.
This property is used only if actions are extracted from screen (Options from screen property set to true).
Comment String configuration Describes the object comment to include in the documentation report.
This property generally contains an explanation about the object.
End pattern String configuration When extracting actions from the screen, defines the actions block end pattern (if applicable).

For example, if actions are grouped between brackets, the end pattern is the closing bracket. The rule is applied only if the block ends with this pattern.
This property is used only if actions are extracted from screen (Options from screen property set to true).
Extraction policy int configuration Defines the policy for extracting the action value (one character to send in the field) related to each action of the action list.

This property defines how to find the action value to send in the field corresponding to each action label from the action list. It can take three values:

index: the action value is its rank in the action list,
character separator: the action value is separated from its label thanks to a character separator, which is defined in Action label separators property,
first upper letter: the action value is the first upper letter the action label.
This property is used only if actions are extracted from screen (Options from screen property set to true).
Is active boolean configuration Defines whether the extraction rule is active.
Is final boolean configuration Defines if the extraction is final, i.e. whether pending extraction rules should try to match on the current extraction rule matching blocks.

If set to true, once the rule applies on a matching block, Convertigo doesn’t apply the following rules on this block. This can be used to prevent a block from being modified by other rules.
Options from screen boolean configuration Defines whether options should be retrieved from the screen.
If set to true, possible actions are extracted from the screen. Otherwise, actions are as set in the Actions table.
Radio buttons boolean configuration Defines whether options should be displayed as radio buttons or combo box.
If set to true, the extraction rule adds a radio attribute with the value true to the choice XML element. Otherwise, it adds a a radio attribute with the value false.
This attribute is processed by the choice XSL template in the choice.xsl file. When attribute value is true, possible actions are displayed as radio buttons, otherwise, possible actions are displayed as a combo box.
Start pattern String configuration When extracting actions from the screen, defines the actions block start pattern (if applicable).

For example, if actions are grouped between brackets, the start pattern is the opening bracket. The rule is applied only if the block starts with this pattern.
This property is used only if actions are extracted from screen (Options from screen property set to true).
Tag name String configuration Defines the tag name of the element generated in output XML after extraction (by default: choice).
By default, the generated element is of choice type. It is processed by the choice XSL template in the choice.xsl file.
Attributes int selection Defines the presentation attributes on which the rule applies, i.e. the rule applies on blocks matching these presentation attributes.
This property allows to configure the rule so that it applies only to parts of screens having specific attributes, for example green text on black background.
Presentation attributes to configure are :

Color: Foreground color, Background color, to choose in a list of predefined colors or “not to take into account”.
Decoration: bold, reverse, underlined, blink, for each decoration choose between “with the decoration”, “normal” (i.e. without the decoration), or “not to take into account”.
Screen zone XMLRectangle selection Defines the screen zone on which the rule applies, i.e. the rule applies on blocks completely contained in this screen area.
This property allows to configure the rule so that it applies only to areas of screens. All blocks found within the specified perimeter are matching this screen zone and can be processed by the rule.
The screen area is defined through four coordinates:

• x (area left corner),
• y (area upper corner),
• w (area width),
• h (area height).

All values are given in characters, with the upper left corner being (x=0, y=0).
-1 represents an undefined value: (x=-1, y=-1, w=-1, h=-1) is an undefined area representing the whole screen, i.e. all blocks, whatever their coordinates, are matching this screen zone and can be processed by the rule.
Type String selection Defines, using a regular expression, to which block types the rule applies.
For example, if set to:

static, the rule applies to blocks of static type only.
static | field, the rule applies to blocks of static or field type only.
[^field], the rule applies to all but field type blocks.

Notes:

• For more information about regular expression patterns, see the following page: http://www.regular-expressions.info/reference.html.
• To test regular expressions, you can use the regular expression tester at the following URL: http://www.regular-expressions.info/javascriptexample.html.