# Javascript: TextFrame.getBorderColor Method

> Gets the border color of the text frame.

- **Product:** DS Server
- **Section:** Reference
- **Kind:** Method
- **Introduced:** 30.0
- **Path:** DS Server > Reference > JavaScript API > Javascript: TextFrame.getBorderColor Method
- **321 words**
- **Web URL:** https://docs.textcontrol.com/ds-server/reference/javascript/textframe/getbordercolor-method/
- **LLMs URL:** https://docs.textcontrol.com/ds-server/reference/javascript/textframe/getbordercolor-method/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/ds-server/reference/javascript/textframe/getbordercolor-method/llms-full.txt

---

### Description

Gets the border color of the text frame.

### Syntax

```javascript
<void> TextFrame.getBorderColor(<RequestStringCallback> callback, [<ErrorCallback> errorCallback])
```

### Parameters

| Parameter | Description |
|---|---|
| callback | Receives the color as a CSS color string. |
| errorCallback | Optional. Is called when the operation failed with an error. |

### Examples

The following example demonstrates `TextFrame.getBorderColor` in a practical document-editing workflow. It gets the border color of the text frame.

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

function inspectBorderColor(textFrame) {
    textFrame.getBorderColor(
        function(result) {
            console.log("get border color result:", result);
        },
        onTxError
    );
}
```

---

## Nearby

- **Previous:** [Javascript: TextFrame.getBackColor Method](https://docs.textcontrol.com/ds-server/reference/javascript/textframe/getbackcolor-method/llms-full.txt)
- **Next:** [Javascript: TextFrame.getBorderStyle Method](https://docs.textcontrol.com/ds-server/reference/javascript/textframe/getborderstyle-method/llms-full.txt)
