DsPdfJS API - v9.1.0
    Preparing search index...

    Class ListBoxField

    Represents the ListBox field.

    Hierarchy (View Summary)

    Index

    Constructors

    Accessors

    • get alternateName(): string | null

      Gets or sets an alternate field name to be used in place of the actual field name wherever the field must be identified in the user interface (such as in error or status messages referring to the field). This text is also useful when extracting the document's contents in support of accessibility to users with disabilities or for other purposes.

      Returns string | null

    • set alternateName(value: string | null): void

      Gets or sets an alternate field name to be used in place of the actual field name wherever the field must be identified in the user interface (such as in error or status messages referring to the field). This text is also useful when extracting the document's contents in support of accessibility to users with disabilities or for other purposes.

      Parameters

      • value: string | null

      Returns void

    • get calculationIndex(): number

      Gets or sets an index that is used to determine the field's calculation order. Fields with lower indices are calculated before fields with higher indices.

      If several fields have the same CalculationIndex, the calculation order is determined by the order of fields in the collection.

      recalculateValue can be used to specify JavaScript that is used to calculate the field's value.

      Returns number

    • set calculationIndex(value: number): void

      Gets or sets an index that is used to determine the field's calculation order. Fields with lower indices are calculated before fields with higher indices.

      If several fields have the same CalculationIndex, the calculation order is determined by the order of fields in the collection.

      recalculateValue can be used to specify JavaScript that is used to calculate the field's value.

      Parameters

      • value: number

      Returns void

    • get commitOnSelChange(): boolean

      Gets or sets a value indicating whether the new value is committed as soon as a selection is made with the pointing device. This option enables applications to perform an action once a selection is made, without requiring the user to exit the field. If false, the new value is not committed until the user exits the field.

      Returns boolean

    • set commitOnSelChange(value: boolean): void

      Gets or sets a value indicating whether the new value is committed as soon as a selection is made with the pointing device. This option enables applications to perform an action once a selection is made, without requiring the user to exit the field. If false, the new value is not committed until the user exits the field.

      Parameters

      • value: boolean

      Returns void

    • get defaultSelectedIndex(): number

      Gets or sets the index of item selected by default.

      Returns number

    • set defaultSelectedIndex(value: number): void

      Gets or sets the index of item selected by default.

      Parameters

      • value: number

      Returns void

    • get defaultSelectedIndexes(): number[] | null

      Gets or sets the indexes of default selected items.

      Returns number[] | null

    • set defaultSelectedIndexes(value: number[] | null): void

      Gets or sets the indexes of default selected items.

      Parameters

      • value: number[] | null

      Returns void

    • get defaultValue(): string | number | boolean | number[] | null

      Gets or sets the field's default value.

      Returns string | number | boolean | number[] | null

    • set defaultValue(value: string | number | boolean | number[] | null): void

      Gets or sets the field's default value.

      Parameters

      • value: string | number | boolean | number[] | null

      Returns void

    • get export(): boolean

      Gets or sets a value indicating whether the field must not be exported by a ActionSubmitForm action.

      Returns boolean

    • set export(value: boolean): void

      Gets or sets a value indicating whether the field must not be exported by a ActionSubmitForm action.

      Parameters

      • value: boolean

      Returns void

    • get formatValue(): ActionJavaScript | null

      Gets or sets a JavaScript action to be performed before the field is formatted to display its current value. This action can modify the field's value before formatting.

      Returns ActionJavaScript | null

    • set formatValue(
          value: ActionJavaScriptProperties | ActionJavaScript | null,
      ): void

      Gets or sets a JavaScript action to be performed before the field is formatted to display its current value. This action can modify the field's value before formatting.

      Returns void

    • get id(): number

      Gets the reference to the object.

      Returns number

    • get keyPress(): ActionJavaScript | null

      Gets or sets a JavaScript action to be performed when the user types a keystroke into a text field or combo box or modifies the selection in a scrollable list box. This action can check the keystroke for validity and reject or modify it.

      Returns ActionJavaScript | null

    • set keyPress(value: ActionJavaScriptProperties | ActionJavaScript | null): void

      Gets or sets a JavaScript action to be performed when the user types a keystroke into a text field or combo box or modifies the selection in a scrollable list box. This action can check the keystroke for validity and reject or modify it.

      Returns void

    • get mappingName(): string | null

      Gets or sets the mapping name to be used when exporting interactive form field data from the document.

      Returns string | null

    • set mappingName(value: string | null): void

      Gets or sets the mapping name to be used when exporting interactive form field data from the document.

      Parameters

      • value: string | null

      Returns void

    • get multiSelect(): boolean

      Gets or sets a value indicating whether more than one of the field's option items may be selected simultaneously.

      Returns boolean

    • set multiSelect(value: boolean): void

      Gets or sets a value indicating whether more than one of the field's option items may be selected simultaneously.

      Parameters

      • value: boolean

      Returns void

    • get name(): string | null

      Gets or sets the field's name.

      Returns string | null

    • set name(value: string): void

      Gets or sets the field's name.

      Parameters

      • value: string

      Returns void

    • get page(): PdfPage | null

      Gets or sets the PdfPage containing this field. This property wraps the WidgetAnnotation#page property and functions identically to: this.widget.page = value;

      Note that a field may have multiple associated annotations across different pages. These can be added and configured using the @widgets property.

      Returns PdfPage | null

    • set page(value: PdfPage | null): void

      Gets or sets the PdfPage containing this field. This property wraps the WidgetAnnotation#page property and functions identically to: this.widget.page = value;

      Note that a field may have multiple associated annotations across different pages. These can be added and configured using the @widgets property.

      Parameters

      Returns void

    • get parent(): Field | null

      Gets the parent field.

      Returns Field | null

    • get readOnly(): boolean

      Gets or sets a value indicating whether the user may not change the value of the field. Any associated widget annotations will not interact with the user; that is, they will not respond to mouse clicks or change their appearance in response to mouse motions. This flag is useful for fields whose values are computed or imported from a database.

      Returns boolean

    • set readOnly(value: boolean): void

      Gets or sets a value indicating whether the user may not change the value of the field. Any associated widget annotations will not interact with the user; that is, they will not respond to mouse clicks or change their appearance in response to mouse motions. This flag is useful for fields whose values are computed or imported from a database.

      Parameters

      • value: boolean

      Returns void

    • get recalculateValue(): ActionJavaScript | null

      Gets or sets a JavaScript action to be performed to recalculate the value of this field when that of another field changes.

      Returns ActionJavaScript | null

    • set recalculateValue(
          value: ActionJavaScriptProperties | ActionJavaScript | null,
      ): void

      Gets or sets a JavaScript action to be performed to recalculate the value of this field when that of another field changes.

      Returns void

    • get rect(): Rect

      Gets or sets the rectangle that defines the location and size of the field on a page. This property wraps the WidgetAnnotation#rect property and functions identically to: this.widget.rect = value;

      Note that a field may have multiple associated annotations across different pages. These can be added and configured using the @widgets property.

      Returns Rect

    • set rect(value: Rect): void

      Gets or sets the rectangle that defines the location and size of the field on a page. This property wraps the WidgetAnnotation#rect property and functions identically to: this.widget.rect = value;

      Note that a field may have multiple associated annotations across different pages. These can be added and configured using the @widgets property.

      Parameters

      Returns void

    • get required(): boolean

      Gets or sets a value indicating whether the field must have a value at the time it is exported by a ActionSubmitForm action.

      Returns boolean

    • set required(value: boolean): void

      Gets or sets a value indicating whether the field must have a value at the time it is exported by a ActionSubmitForm action.

      Parameters

      • value: boolean

      Returns void

    • get selectedIndex(): number

      Gets or sets the index of selected item.

      Returns number

    • set selectedIndex(value: number): void

      Gets or sets the index of selected item.

      Parameters

      • value: number

      Returns void

    • get selectedIndexes(): number[] | null

      Gets or sets the indexes of selected items.

      Returns number[] | null

    • set selectedIndexes(value: number[] | null): void

      Gets or sets the indexes of selected items.

      Parameters

      • value: number[] | null

      Returns void

    • get sort(): boolean

      Gets or sets a value indicating whether the field's option items should be sorted alphabetically. This flag is intended for use by form authoring tools, not by PDF viewer applications. Viewers should simply display the options in the order in which they occur in the Opt array

      Returns boolean

    • set sort(value: boolean): void

      Gets or sets a value indicating whether the field's option items should be sorted alphabetically. This flag is intended for use by form authoring tools, not by PDF viewer applications. Viewers should simply display the options in the order in which they occur in the Opt array

      Parameters

      • value: boolean

      Returns void

    • get spellCheck(): boolean

      Gets or sets a value indicating whether the text entered in the field is spell-checked.

      Returns boolean

    • set spellCheck(value: boolean): void

      Gets or sets a value indicating whether the text entered in the field is spell-checked.

      Parameters

      • value: boolean

      Returns void

    • get topIndex(): number

      Gets or sets the index of top visible item.

      Returns number

    • set topIndex(value: number): void

      Gets or sets the index of top visible item.

      Parameters

      • value: number

      Returns void

    • get value(): string | number | boolean | number[] | null

      Gets or sets the field's value.

      Returns string | number | boolean | number[] | null

    • set value(value: string | number | boolean | number[] | null): void

      Gets or sets the field's value.

      Parameters

      • value: string | number | boolean | number[] | null

      Returns void

    • get valueChanged(): ActionJavaScript | null

      Gets or sets a JavaScript action to be performed when the field's value is changed. This action can check the new value for validity.

      Returns ActionJavaScript | null

    • set valueChanged(
          value: ActionJavaScriptProperties | ActionJavaScript | null,
      ): void

      Gets or sets a JavaScript action to be performed when the field's value is changed. This action can check the new value for validity.

      Returns void

    Methods