ReferenceFunctionsEngineering Functions
BIN2HEX
BIN2HEX: Converts a binary text value to hexadecimal text.
Summary
Optionally pads the output with leading zeros using places.
Remarks
- Input must be a binary string up to 10 digits; 10-digit values may be signed.
- Signed binary values are converted using two's-complement semantics.
placesmust be at least the output width and at most10, or#NUM!is returned.
Examples
Convert binary to hex
Grid
| Cell | Value | |
|---|---|---|
| No inputs on Sheet1. | ||
Formula
=
Result
Not evaluated yet.
Expected
A
Pad hexadecimal output
Grid
| Cell | Value | |
|---|---|---|
| No inputs on Sheet1. | ||
Formula
=
Result
Not evaluated yet.
Expected
000A
Related functions
FAQ
Does BIN2HEX preserve signed binary meaning?
Yes. A 10-bit binary with leading 1 is interpreted as signed and converted using two's-complement semantics.
Runtime metadata
Category
Engineering
Signature
BIN2HEX(arg1: Number, arg2…: Number)Arity
min 1, max variadic
Arguments
arg1Number · Scalar · coercion NumberLenientText
arg2Number · Scalar · coercion NumberLenientText
Caps
PURE
Source