# Javascript: ListFormat.getLevel Method

> Gets the level for a bulleted or numbered list.

- **Product:** DS Server
- **Section:** Reference
- **Kind:** Method
- **Introduced:** 28.0
- **Path:** DS Server > Reference > JavaScript API > Javascript: ListFormat.getLevel Method
- **293 words**
- **Web URL:** https://docs.textcontrol.com/ds-server/reference/javascript/listformat/getlevel-method/
- **LLMs URL:** https://docs.textcontrol.com/ds-server/reference/javascript/listformat/getlevel-method/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/ds-server/reference/javascript/listformat/getlevel-method/llms-full.txt

---

### Description

Gets the level for a bulleted or numbered list.

### Syntax

```javascript
<void> ListFormat.getLevel(<RequestNumberCallback> callback, [<ErrorCallback> errorCallback])
```

### Parameters

| Parameter | Description |
|---|---|
| callback | Receives the level for a bulleted or numbered list. |
| errorCallback | Optional. Is called when the operation failed with an error. |

### Examples

The following example demonstrates `ListFormat.getLevel` in a practical document-editing workflow. It gets the level for a bulleted or numbered list.

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

TXTextControl.listFormat.getLevel(
    function(result) {
        console.log("get level result:", result);
    },
    onTxError
);
```

---

## Nearby

- **Previous:** [Javascript: ListFormat.getLeftIndent Method](https://docs.textcontrol.com/ds-server/reference/javascript/listformat/getleftindent-method/llms-full.txt)
- **Next:** [Javascript: ListFormat.getNumberFormat Method](https://docs.textcontrol.com/ds-server/reference/javascript/listformat/getnumberformat-method/llms-full.txt)
