Search code examples
excel-formulaexcel-2007

Copy formatted text and store as cell value in Excel 2007


I have cells formatted to put a string of less than or equal to 11 numbers into the format of #####-####-##.

How can I take the formatted value and store is as the actual cell value in another cell?

eg.

Cell A1 has value 12345678, and is formatted to display 00012-3456-78. I want cell B1 to have a cell value of 00012-3456-78.


Solution

  • Try this in B1:

    =TEXT(A1, "00000-0000-00")
    

    Hope this helps.