Auto fill hex values without a helper column

Viewed 499

I am creating a spreadsheet with multiple columns of hex values and I would like to be able to auto fill their values by dragging as I can with decimal values. For example, if the first two rows in a column contain FFFFFF00 and FFFFFF04, I would like to be able to drag it down two rows and see FFFFFF08 and FFFFFF0C.

Of course, excel treats everything as a decimal value by default, so if you try to do what I mentioned above you will end up with the values FFFFFF08 and FFFFFF12.

I found a workaround to this using =DEC2HEX() where I use a helper column to supply the offset, as seen below. This works fine, but I have to have a helper column for every sequence of hex values I want auto filled.

enter image description here

Is there any easier way to auto fill hex values?

1 Answers

As you have found Excel only does math in Decimal. So change the values to decimal do the math and change back to hex.

In the third cell put:

=DEC2HEX(HEX2DEC(A3)+HEX2DEC(A3)-HEX2DEC(A2))

Then drag down.

enter image description here

Related