HEX2DEC function

HEX2DEC(Number) HEX2DEC(Number)

Number

Text or { Text }

A hexadecimal number.

Returns

Number or { Number }

A decimal number.

Converts a hexadecimal number to a decimal number. Also consider using the more general function DECIMAL. Perform the reverse conversion using DEC2HEX.

Examples

HEX2DEC("5")HEX2DEC("5")

Returns 5.

HEX2DEC("7B")HEX2DEC("7B")

Returns 123.

DECIMAL("7B", 16)DECIMAL("7B"; 16)

Returns 123.

HEX2DEC({ "5", "7B" })HEX2DEC({ "5"; "7B" })

Returns the array { 5, 123 }{ 5; 123 }.