Excel – Concatenating numbers that have leading zeros

concatenationmicrosoft excelmicrosoft-excel-2010

I'm trying to combine/concatenate numbers in different columns into one long number. Some of the numbers have leading zeros because of custom formats applied to the cells. When I concatenate them together, the zeros are removed. Does someone know how the formula should look so that the leading zeros aren't removed?

Example:
A1 = 08,
B1 = 7,
C1 = 0,
D1 = 17,
E1 = 00,
F1 = 01,
G1 = Concentrated number from A1 to F1

The resulting number should be 0870170001 however the following number appears 8701701.

I'm using Excel 2010, and this is the formula I've tried: =CONCATENATE(A1;B1;C1;D1;E1;F1).

Best Answer

You may not need the ; but instead, use a comma to show each is a separate string value (this may depend on localization settings - Thanks Bob).

=CONCATENATE(A1,B1,C1,D1,E1,F1)

However, you will need to make sure that the cells with the numbers in are formatted to text by highlighting the row and in the Home ribbon, under Number tab, in the drop down list select 'Text'.

enter image description here