Web3S_Demo > Web 3S String Utils Function Library > BytesToHex

BytesToHex

Converts the byte array to a string containing the corresponding
character byte values written in two-digit lowercase hex format.

Inputs

Bytes
Array of Bytes

Byte array.

With Prefix
Boolean

If true, the hex code will be prefixed with "0x" (Default: True).

Outputs

Return Value
String

Hex string from byte array; will be empty if conversion fails.