View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
a a is offline
external usenet poster
 
Posts: 51
Default Preserving leading zero

Davey,

Thanks for responding. I did format the column as text but that doesn't
seem to be enough. I've even tried using cstr but, as the text comes
from another sheet and then I replace the "-" with nothing, the cstr
won't work because of the timing. Once the "-" has been replaced, the
leading zero is gone.

For instance, the text is "003-500". It comes from a cell that is
formatted as text into another spreadsheet which is also formatted as
text. Once the "-" is replaced, it becomes a value even though the cell
formatting is still "text".

Any other thoughts?

Best Regards,
Anita

DaveyJones wrote:

You can format the cell as text, then whatever you type, it will display that
unchanged.