HEX2BIN Help

J

Jon S.

Hi, I'e have to columns A and B. IN the A column I have a
HEX number, in the B column I want to display the BIN
conversion of the HEX number in A.

The problem is the HEX2BIN function won't allow you to
put a Cell value into it. =HEX2BIN("A1") converts the
value A1 to hex. I want it to convert the value in cell
A1. Any ideas?

Thanks,
Jon
 
H

hgrove

Jon S. wrote...
...
The problem is the HEX2BIN function won't allow you to
put a Cell value into it. =HEX2BIN("A1") converts the
value A1 to hex. I want it to convert the value in cell
A1. Any ideas?

Eliminate the double quotes, use

=HEX2BIN(A1
 
J

Jon S.

Thanks and that does work on a small hex number
like 'FF'. But it won't work on 'abcd0123' for example.

Any ideas?
 
H

hgrove

Jon S. wrote...
Thanks and that does work on a small hex number like 'FF'. But
it won't work on 'abcd0123' for example.
...

Would have been useful if you had provided some notion of the range o
the hexadecimal numbers you were working with in your previous posts.

Simple enough to handle.

=HEX2BIN(LEFT(RIGHT("00000000"&A1,8),2),8)
&HEX2BIN(LEFT(RIGHT("00000000"&A1,6),2),8)
&HEX2BIN(LEFT(RIGHT("00000000"&A1,4),2),8)
&HEX2BIN(RIGHT("00000000"&A1,2),8
 
J

Jon S.

Sorry about that! Thank you very much for your help and
expertise. It works great!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top