# Javascript: TXTextControl.TextType Enumeration

> Specifies how a text is represented and interpreted.

- **Product:** TX Text Control .NET Server
- **Section:** Reference
- **Kind:** Enumeration
- **Path:** TX Text Control .NET Server > Reference > JavaScript API > Javascript: TXTextControl.TextType Enumeration
- **276 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/txtextcontrol/texttype-enumeration/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/txtextcontrol/texttype-enumeration/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/txtextcontrol/texttype-enumeration/llms-full.txt

---

### Description

Specifies how a text is represented and interpreted.

### Members

| Member | Description |
|---|---|
| Text | The text type is text and it is displayed as it is. |
| Number | The text is interpreted as a number. |

### Examples

The following example uses `TXTextControl.TextType.Text` (the text type is text and it is displayed as it is.) in a document-editing workflow.

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

function applyTextType(tableCellFormat) {
    tableCellFormat.setTextType(
        TXTextControl.TextType.Text,
        function() {
            console.log("set text type completed.");
        },
        onTxError
    );
}
```

---

## Nearby

- **Previous:** [Javascript: TXTextControl.textParts Property](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/txtextcontrol/textparts-property/llms-full.txt)
- **Next:** [Javascript: TXTextControl.undo Method](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/txtextcontrol/undo-method/llms-full.txt)
