Data Field

Represents a field.

Remarks

Fields can be children of Data Model or Data Section objects. Field objects have properties which define characteristics such as:

Inherits from: Data Element

Properties

The following 34 properties are defined.

Property Name Description
General
Value Type Type: Storage Type

Defines what type of information this field will contain. Any value extracted or entered into the field which cannot be converted to the Value Type will place the field into an error state.

Value Extractor Type: Value Extractor

The default extractor to use for this field. The default extractor can be overridden on individual Content Types.

Minimum Confidence Type: Double, Default: 20%, Range: 0% - 100%

The minimum confidence required for extracted values. Any extracted field value with a confidence lower than this threshold will be excluded.

Sub-Element Name Type: String

Indicates the subelement of the field's data type to be used as the value for this field. For example, the built-in Address Data Type defines Address, City, State, and ZIP as subelements. To capture only the City from the address value, select the Address Data Type and indicate "City" as the subelement.

Description Type: String

Specifies a description for the item.

Appearance
Alignment Type: HorizontalAlignment, Default: Left

The text alignment for this field. Can be one of the following values:

  • Left - The object or text is aligned on the left of the control element.
  • Right - The object or text is aligned on the right of the control element.
  • Center - The object or text is aligned in the center of the control element.

Display Width Type: Int32, Default: 100

The width of the field in pixels. Controls the width of the control which represents the field in the Index Panel. If the parent element is a Data Table, then this value specifies the column width.

Error Color Type: Color, Default: 255, 192, 192

The background color to use when the field has a validation error.

Background Color Type: Color, Default: Window

The background color for this item.

Foreground Color Type: Color, Default: WindowText

The foreground color for this item.

Visible Type: Boolean, Default: True

Controls whether this item is visible in the user interface.

Label Position Type: LabelPositionEnum, Default: Left

Controls how the label for this item is displayed. Can be one of the following values:

  • Left - The label is displayed to the left of the item.
  • Above - The label is displayed above the item.
  • Below - The label is displayed below the item.
  • None - The label will not be displayed.

Label Alignment Type: ContentAlignment, Default: MiddleLeft

The text alignment to be used for the data element's label. Can be one of the following values:

  • TopLeft - Content is vertically aligned at the top, and horizontally aligned on the left.
  • TopCenter - Content is vertically aligned at the top, and horizontally aligned at the center.
  • TopRight - Content is vertically aligned at the top, and horizontally aligned on the right.
  • MiddleLeft - Content is vertically aligned in the middle, and horizontally aligned on the left.
  • MiddleCenter - Content is vertically aligned in the middle, and horizontally aligned at the center.
  • MiddleRight - Content is vertically aligned in the middle, and horizontally aligned on the right.
  • BottomLeft - Content is vertically aligned at the bottom, and horizontally aligned on the left.
  • BottomCenter - Content is vertically aligned at the bottom, and horizontally aligned at the center.
  • BottomRight - Content is vertically aligned at the bottom, and horizontally aligned on the right.

Behavior
Auto Complete Type: Auto Complete Settings

Enables or disables autocomplete for this field. Can be one of the following values:

  • Enabled
  • Disabled

Input Mask Type: Mask Settings

Defines input masking settings. Can be one of the following values:

  • Enabled
  • Disabled

Multi Line Type: Multi Line Settings

Defines multi-line input settings. Can be one of the following values:

  • Enabled
  • Disabled

Tooltip Type: String

The tooltip to display when a user hovers the mouse over this field. Include user assistance instructions here.

Read Only Type: Boolean, Default: False

If set to true, the field will not be editable in the user interface.

Required Type: Boolean, Default: False

If set to true, a value is required in the field.

Sticky Type: Boolean, Default: False

If set to true, the field's value will persist when moving to the next document in data review.

Requires Validation Type: Boolean, Default: False

If set to true, this field will require operator review. When Require Validation is enabled, the field will be created in an error state, and will remain in an error state until a user enters and leaves the field in the Index Panel. This feature is designed to ensure that a field receives human review.

Spell Correction Type: Spell Corrector

If set to true, this field will require operator review. Can be one of the following values:

  • Enabled
  • Disabled
When Require Validation is enabled, the field will be created in an error state, and will remain in an error state until a user enters and leaves the field in the Index Panel. This feature is designed to ensure that a field receives human review.

Character Casing Type: CharacterCasing, Default: Normal

Controls the character casing of this field. Can be one of the following values:

  • Normal - The case of characters is left unchanged.
  • Upper - Converts all characters to uppercase.
  • Lower - Converts all characters to lowercase.

Preserve Character Data Type: Boolean, Default: False

Indicates whether character-level position and confidence data should be saved. If true, character-level detail will be saved with the data element. If false, only the raw text of the element's value will be saved. As storing this information increases storage requirements and reduces performance, this feature should only be enabled for individual data elements in cases where it is needed.

Character-level data can be useful in custom activities or custom export sceanrios, and is also used in certain built-in Grooper activities.

Rubberband OCR Profile Type: OCR Profile

The OCR Profile to use for rubberband OCR.

Expressions
Default Value Expression Type: String

Generates the default value for the field. The expression must evaluate to a value matching the Value Type of the field. Below are various examples of default value expressions:

Default to a literal string value:
"None"

Default to a literal numeric value:
25.00

Default to the current date and time:
DateTime.Now

Default to the current date:
DateTime.Today

Default to the current user name:
Environment.UserName

Default to the current machine name:
Environment.MachineName

Default to the MIME type of the document:
Folder.NativeMimeType

Default to the name of the Content Type assigned to the document:
ContentTypeName

Default to the "Subject" metadata element of a PDF file:
DirectCast(Handler, PdfMimeTypeHandler).Subject

Default to the filename associated with a File System Link:
DirectCast(Link, FileSystemLink).Filename

Default to the filename associated with a File System Link without the extension:
IO.Path.GetFileNameWithoutExtension(DirectCast(Link,FileSystemLink).FilePath)

Default to the name of the 2nd directory level associated with a File System Link:
Link.GetPathSegment(1)

Default to the sender associated with a Mail Message:
DirectCast(Handler, MailMimeTypeHandler).From

Generate a unique idenfier:
Guid.NewGuid

Generated Default Value Type: String

A preview of the default value for this field with variables inserted.

Calculate Expression Type: String

Calculates the expected value for a field. A Calculate Expression is a VB.Net code snippet which calculates the value for a field based on the value of other fields - similar to the way a formula defines a relationship between various cells in a spreadsheet. Depending on the value of the 'Calculate Mode' property, the expression can be used to validate the field or automatically populate its value.

The expression must produce a value compatible with the field's Value Type. If the field is a Decimal type, the expression should evaluate to a Decimal value. If the field is a DateTime type, the expression should evaluate to a DateTime value. If the expression produces an invalid value which cannot be converted to the field's type, the field will be set to an error state.

Simple Examples

Below are various examples of simple calculate expressions:
ExpressionDecription
Math.Round(Quantity * Unit_Price,2)Returns the product of the 'Quantity' and 'Unit Price' fields.
Subtotal + Sales_TaxReturns the sum of the 'Subtotal' and 'Sales Tax' fields.
Invoice_Date.AddDays(30)Returns the value of the 'Invoice Date' field, plus 30 days.
Line_Items.SumOf("Line Total")Returns the sum of the 'Line Total' column in the 'Line Items' table.
Semester.SumOf("Earned Hours")Returns the sum of the 'Earned Hours' field from all instances of the 'Semester' section
Utilities.CalculateValue(Instance)Call a static method named CalculateValue() in the 'Utilities' object library.

LINQ Examples

Expressions may use LINQ syntax to access information in collections, such as tables and multi-instance sections.

ExpressionDecription
(From Row in Line_Items Select Row.Line_Total).SumReturns the sum of the 'Line Total' column in the 'Line Items' table.
(From Sem In Semester Select Sem.Earned_Hours).MaxReturns the maximum of the 'Earned Hours' field from all instances of the 'Semester' section
(From Sem In Semester From Row in Sem.Courses Select Row.GPA).AverageReturns the average of the 'GPA' field from all 'Courses' table rows in all instances of the 'Semester' section.
(From Sem In Semester Where Sem.Year < DateTime.Now.Year
Select Sem.Earned_Hours).Sum
Returns the total 'Earned Hours' for semesters prior to the current year.

Calculate Mode Type: CalculateModeEnum, Default: Validate

When a Calculate Expression is provided, this property controls the behavior when the field is calculated. Can be one of the following values:

  • Validate - The expression is used to validate the field value.
  • SetIfEmpty - If the field is empty, it will be populated with the calculated value. Otherwise, the existing value will be validated.
  • AlwaysSet - The field value will be always be set to the calculated value. In combination with a Read Only setting, this represents a pure calculated field.

Calculate Tolerance Type: Decimal, Default: 0

The amount of tolerance allowed between a field's value and its calculated value. This setting affects the validation performed by a calculate expression. If this property is set to 0, then the field value must exactly match the calculated value.

Validate Expression Type: String

Defines an expression which determines if the field value is valid or invalid. The expression must evaluate to a Boolean value. Sections, Tables, and Fields which are peers in the Data Model hierarchy may be referenced by name. A return value of True indicates that the value of the field is valid, and false indicates that the field value is invalid. Below are various examples of validate expressions:

Invoice Total must be greater than 0 and less than 100,000:
(Invoice_Total > 0) And (Invoice_Total < 100000)

Invoice Total must be greater than or equal the Subtotal:
Invoice_Total > Subtotal

Invoice Date cannot be older than 90 days:
DateTime.Now.Subtract(Invoice_Date).TotalDays <= 90

Invoice No cannot contain a tilde (~) character:
Not Invoice_No.Contains("~")

Validate Message Type: String

An optional custom message to display when the Validate Expression fails.

List Settings
List Values Type: Embedded Lexicon

An Embedded Lexicon containing values for this field, which can include locally-defined lexicon entries as well as references to external lexicons.

Restrict To List Type: Boolean, Default: False

If set to true, the field only allows values from the list and does not allow free typing.

Commands

Command Name Shortcut Keys Description
Add Multiple Items Creates multiple items as children of the selected object.
Clear Children Deletes all children of the selected object(s).
Export to Zip Archive Exports a set of Grooper nodes to a ZIP archive.
Publish to Grooper Repository Publishes one or more Nodes to one or more Target Grooper Repositories.
Unpublish Unpublishes a set of Grooper Nodes to a Target Grooper Repository.

Tabs

Tab Name Description
Data Element - GeneralProvides a user interface displaying the properties of a Data Element as well as an interface for testing the Data Element on test Batch documents.
Grooper Node - ScriptingProvides script viewing, compilation, management, and basic editing features.
Grooper Node - ContentsProvides a user interface for viewing and managing the children of a Grooper Node.
Grooper Node - AdvancedDisplays detailed information about Grooper Node objects, and provides administrative functions for managing them.

See Also

Auto Complete Settings, Embedded Lexicon, Mask Settings, Multi Line Settings, OCR Profile, Spell Corrector, Storage Type, Value Extractor

Used By

Checkbox Widget, Correct, Document Type, Export Mapping, Field Mapping, Highlight Annotation, Lexicon Lookup, Radio Group Widget, Redact, Signature Widget, Textbox Widget, Train Lexicon