# RequestParagraphStyleCallback Function

> Callback function for requesting a paragraph's style.

- **Product:** TX Text Control .NET Server
- **Section:** Reference
- **Kind:** Function
- **Path:** TX Text Control .NET Server > Reference > JavaScript API > RequestParagraphStyleCallback Function
- **257 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/requestparagraphstylecallback/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/requestparagraphstylecallback/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/requestparagraphstylecallback/llms-full.txt

---

### Description

Callback function for requesting a [paragraph's style](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/paragraphstyle/llms-full.txt).

### Syntax

```javascript
function(<ParagraphStyle> style)
```

### Examples

The following example demonstrates `RequestParagraphStyleCallback` in a practical document-editing workflow. Callback function for requesting a paragraph's style.

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

function requestParagraphStyleCallback(style) {
    console.log("style:", style);
}

TXTextControl.paragraphStyles.getItem("Heading 1", requestParagraphStyleCallback, onTxError);
```

---

## Nearby

- **Previous:** [RequestParagraphFormatCallback Function](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/requestparagraphformatcallback/llms-full.txt)
- **Next:** [RequestPermanentControlCharsCallback Function](https://docs.textcontrol.com/tx-text-control-dotnet-server/reference/javascript/requestpermanentcontrolcharscallback/llms-full.txt)
