# xtd() function

The xtd() function converts an expression
from its hexadecimal format into its equivalent decimal format.

## Syntax

```
xtd(str.exp)
```

## Parameter(s)

| str.exp | Hexadecimal expression to convert to decimal format. |
| --- | --- |

## Description

When a nonhexadecimal string
is passed to the xtd() function, 0 is returned.

## Example(s)

This assigns `10` to `number`.

```
number = xtd("a")
```

## See also

- [BASIC functions](https://d3codex.com/pickbasic-flashbasic/basic-functions/)
- [Statements and functions](https://d3codex.com/pickbasic-flashbasic/statements-and-functions/)

---
Source: https://d3codex.com/pickbasic-flashbasic/xtd-function/ - part of the D3Codex reference.
