byteToNum

Returns the numeric value of a byte.

# Metadata

Platforms: desktop, server, mobile OS: mac, windows, linux, ios, android Introduced: 4.0 Security:

# Syntax

the byteToNum of byte

# Params

- byte : Any <expression> that evaluates to a byte. If you specify a <string> containing more than one byte, all bytes but the first are ignored.

# Examples

byteToNum(byte 1 of tString)

if byteToNum(nextByte) = 0 then next repeat

numToByte(byteToNum("Z")) -- returns Z

# Description

Converts a single byte to a numeric value in the range 0-255

The byteToNum function is the inverse of the numToByte function.

# Tags

# See

- **keyword:** integer - **function:** md5Digest, charToNum, numToByte, numToChar - **control structure:** function