---
url: /flow/guide/scripting-reference/functions/conversion/hextoint.md
---

# HexToInt

## Declaration

`Function HexToInt( HexNum : string) : Int64;`

### Example

```pascal
procedure OnMapEvent(var Value:Variant);
begin
Value := HexToInt(HexadecimalField.Value);
end;
```

## Description

HexToInt converts a String representing a hexadecimal value into Integer data type.

This is used when you need to read into hexadecimal type fields within a database or file.
