# DisplayColor Property

> Returns or sets the display colors used with the txGradientColors page view style: desktop, page shadows, header and footer lines and labels, form fields.

- **Product:** TX Text Control ActiveX
- **Section:** Documentation
- **Kind:** Property
- **Path:** TX Text Control ActiveX > API Reference > TXTextControl > DisplayColor Property
- **412 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/displaycolor-property/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/displaycolor-property/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/displaycolor-property/llms-full.txt

---

This property gets or sets the display colors of a TextControl. With this property all colors can be individually designed. The colors are only used when the text control's [PageViewStyle](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/pageviewstyle-property/llms-full.txt) property has been set to **txGradientColors**.

Introduced: 15.1.

### Syntax

```vbscript
TXTextControl.DisplayColor(index) [= color]
```

### Parameters

| Parameter | Description |
|---|---|
| index | Determines the index of the display element the color of which is changed. It must be a value of the **TextControlColor** enumeration. Possible values are listed in Constants. |

### Constants

Valid values for the index parameter are:

| Constant | Description |
|---|---|
| txDesktopColor (0) | Gets or sets the display color for the area around the pages. |
| txLightShadowColor (1) | Gets or sets the display color for the shadow at the left and the top edge of the pages. |
| txDarkShadowColor (2) | Gets or sets the display color for the shadow at the right and the bottom edge of the pages. |
| txHeaderFooterLineColor (3) | Gets or sets the display color for the dividing line between headers and footers and the main text. |
| txHeaderFooterLabelColor (4) | Gets or sets the display color for the label showing which header or footer is activated. |
| txActiveFormFieldColor (5) | Gets or sets the highlight color of a form field containing the current text input position. |
| txFormFieldColor (6) | Gets or sets the highlight color of a form field. |

### Data Types

| Name | Data type |
|---|---|
| index | Integer |
| Property value | Long |

### Limitations

Run time only.

### See Also

- [Programming Category: Control Settings](https://docs.textcontrol.com/tx-text-control-activex/reference/categories/control-settings/llms-full.txt)

---

## Nearby

- **Previous:** [Device Property](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/device-property/llms-full.txt)
- **Next:** [DocumentPermissions Property](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/documentpermissions-property/llms-full.txt)
