# LEFTB Function

> Return the first characters of a text with LEFTB in TX Sheet Control, which counts characters like LEFT, also for Japanese or Chinese text, unlike Excel.

- **Product:** TX Sheet Control
- **Section:** Documentation
- **Kind:** Function
- **Path:** TX Sheet Control > API Reference > Formula Functions > LEFTB Function
- **226 words**
- **Web URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/leftb/
- **LLMs URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/leftb/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/leftb/llms-full.txt

---

Return the first characters of a text, counted in bytes in Excel for double-byte languages. In TX Sheet Control, LEFTB counts characters as LEFT does, also for Japanese or Chinese text, so `LEFTB("日本語",2)` returns `日本`. `text` is the text, and the second argument, named `argument1` in the syntax, is the number of characters (1 when omitted); a negative number returns `#VALUE!`. The catalog accepts two arguments.

### Syntax

```text
LEFTB(text, argument1, argument2)
```

Category: Text. Minimum arguments: 1. Maximum arguments: 2.

Available for supported offline calculation.

### Examples

```text
=LEFTB("abc")
```

The formula returns `a`.

Cell and range examples require appropriate input values in the referenced cells. Handle invalid arguments, formula errors and array and spill constraints.

### See Also

- [Formulas](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/formulas/llms-full.txt)
- [Custom Functions and Formula Data](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/custom-functions/llms-full.txt)

---

## Nearby

- **Previous:** [LEFT Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/left/llms-full.txt)
- **Next:** [LEN Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/len/llms-full.txt)
