#

# hexstr

### hexstr(string)

Converts each character in a string to its hexadecimal equivalent.

## Arguments

Argument | Data Type | Description
string | string | The string to be converted

## Returns

A string where each character in the original string has been replaced by its hexadecimal value.

## Description

The primary use for this function is to make it easy to store and subsequently query for strings that may have unusual or difficult to handle control characters.

For example the unique IDs in an ACT! database may have just about any character in them. They need to be stored in target systems for subsequent matching and querying, so we use the hexstr() function to map them to a usable string.

##

## Example

Example | Result | Description
--- | --- | ---
hexstr("^7;) \JB0^ ") | 5e373b2920205c4a42305e20 | Each character in the incoming string (an ACT! unique ID) is translated into its hexadecimal value