# TXTextControl.TextField Object

> Represents a text field in a Text Control document. A text field is a marked piece of text that has properties like text or a name.

- **Product:** DS Server
- **Section:** Reference
- **Kind:** Object
- **Introduced:** 25.0
- **Path:** DS Server > Reference > JavaScript API > TXTextControl.TextField Object
- **1135 words**
- **Web URL:** https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/
- **LLMs URL:** https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/llms-full.txt

---

### Description

Represents a text field in a Text Control document. A text field is a marked piece of text that has properties like text or a name.

### Syntax

```javascript
TXTextControl.TextField
```

### Examples

The following example demonstrates `TXTextControl.TextField` in a practical document-editing workflow. It represents a text field in a Text Control document. A text field is a marked piece of text that has properties like text or a name.

```javascript
function onTxError(error) {
    console.error("TX Text Control error:", error.msg);
    error.handled = true;
}

function inspectTextField(textField) {
    textField.getID(
        function(result) {
            console.log("get id result:", result);
        },
        onTxError
    );
}
```

---

## In This Section

- [Javascript: TXTextControl.TextField.bounds Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/bounds-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. The bounding rectangle of a text field. The bounding rectangle is the smallest rectangle which contains all characters of the field's text.
- [Javascript: TXTextControl.TextField Constructor](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/constructor/llms-full.txt): Initializes a new instance of the TextField class.
- [Javascript: TXTextControl.TextField.containsInputPosition Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/containsinputposition-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. Returns true if the Textfield contains the current text input position.
- [Javascript: TXTextControl.TextField.deleteable Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/deleteable-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. Specifies whether a text field can be deleted by the end-user while a TX Text Control document is being edited.
- [Javascript: TXTextControl.TextField.doubledInputPosition Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/doubledinputposition-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. Specifies whether a text field has a doubled input position in front of its first character and behind its last character.
- [Javascript: TXTextControl.TextField.editable Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/editable-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. Specifies whether the text of a text field can be changed by the end-user while a TX Text Control document is being edited.
- [Javascript: TXTextControl.TextField.id Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/id-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. The identifier of the text field.
- [Javascript: TXTextControl.TextField.isSpellCheckingEnabled Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/isspellcheckingenabled-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. Specifies whether a text field's text is checked on misspelled words.
- [Javascript: TXTextControl.TextField.length Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/length-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. The number of characters in the text field.
- [Javascript: TXTextControl.TextField.name Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/name-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. The Text field's name.
- [Javascript: TXTextControl.TextField.showActivated Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/showactivated-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. Specifies whether a text field toggles its background to gray, if the current input position is in the field.
- [Javascript: TXTextControl.TextField.start Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/start-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. The 1-based first character position of the text field.
- [Javascript: TXTextControl.TextField.text Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/text-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. The Text field's text.
- [Javascript: TXTextControl.TextField.type Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/type-property/llms-full.txt): Obsolete. This property will be removed in one of the next versions. The field type ("APPLICATIONFIELD" or "TEXTFIELD").

---

## Nearby

- **Previous:** [Javascript: TXTextControl.TabType Enumeration](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol/tabtype-enumeration/llms-full.txt)
- **Next:** [Javascript: TXTextControl.TextField.bounds Property](https://docs.textcontrol.com/ds-server/reference/javascript/txtextcontrol-textfield/bounds-property/llms-full.txt)
