Hi there, hoping some one can help:

I have set up a filename builder where a user can pick a value for each code that forms part of a document reference number. the last part of this number is a sequential 4 digit number which increments automatically using an "if" formula by one digit each time. The sequential number then has leading zeroes to ensure that it appears as a 4 digit number. To do this set the custom format field to #### and this works fine so that 1 automatically becomes 0001, 20 becomes 0020, 999 becomes 0999, etc. However, when the following formula is applied to concatenate the codes into a document reference number, the sequential number loses its leading zeroes. E.g., a user selects the following codes:

BR- 0300- 01- GF- DR- X- G13- 0002

The formula used to join these up is:

=B190&C190&D190&E190&F190&G190&H190&I190

but the result I get is:

BR-0300-01-GF-DR-X-G13-2 instead of BR-0300-01-GF-DR-X-G13-0002

Note I am using google spreadsheets but the problem is the same in Excel. so how can I preserve the 4 digit sequential number in the resulting document reference number?