Mark Lincoln said:
Can you provide some examples?
Well....
When I found that they didn't seem to work,
I pasted in all the examples given in the HELP file - and those two STILL
didn't work !
From my spreadsheet:-
DEC2HEX(number,places)
Number is the decimal integer you want to convert. If number is negative,
places is ignored and DEC2HEX returns a 10-character (40-bit) hexadecimal
number in which the most significant bit is the sign bit. The remaining 39
bits are magnitude bits. Negative numbers are represented using
two's-complement notation.
Places is the number of characters to use. If places is omitted, DEC2HEX
uses the minimum number of characters necessary. Places is useful for padding
the return value with leading 0s (zeros).
#NAME? Converts decimal 100 to hexadecimal with 4 characters (0064)
#NAME? Converts decimal -54 to hexadecimal (FFFFFFFFCA)
Those two cells returning #NAME? contain:
=DEC2HEX(100, 4)
=DEC2HEX(-54)
HEX2DEC(number)
Number is the hexadecimal number you want to convert. Number cannot
contain more than 10 characters (40 bits). The most significant bit of number
is the sign bit. The remaining 39 bits are magnitude bits. Negative numbers
are represented using two's-complement notation.
#NAME? Converts hexadecimal A5 to decimal (165)
#NAME? Converts hexadecimal FFFFFFFF5B to decimal (-165)
#NAME? Converts hexadecimal 3DA408B9 to decimal (1034160313)
Those three cells returning #NAME? contain:
=HEX2DEC("A5")
=HEX2DEC("FFFFFFFF5B")
=HEX2DEC("3DA408B9")
HEX2BIN(number,places)
Number is the hexadecimal number you want to convert. Number cannot
contain more than 10 characters. The most significant bit of number is the
sign bit (40th bit from the right). The remaining 9 bits are magnitude bits.
Negative numbers are represented using two's-complement notation.
Places is the number of characters to use. If places is omitted, HEX2BIN
uses the minimum number of characters necessary. Places is useful for padding
the return value with leading 0s (zeros).
00001111 Converts hexadecimal F to binary, with 8 characters (00001111)
10110111 Converts hexadecimal B7 to binary (10110111)
1111111111 Converts hexadecimal FFFFFFFFFF to binary (1111111111)
Those three cells contain:
=HEX2BIN("F", 8)
=HEX2BIN("B7")
=HEX2BIN("FFFFFFFFFF")
Regards
Robin Clay
Robin_B DOT Clay AT virgin DOT net
In Dorset's Blackmore Vale