Find and Replace - Auto Cell Formats

B

bslater

I have a column of date data that is in text format by design. I want
to do a find and replace for this column to change "/2003" to "/03",
"/2004" to "/04", etc. I have coded this into my macro, but Excel
automatically sets the cell format to a date type when the find and
replace occurs. Is there any way to stop this from happening? Can I
lock the format of these cells?

Thanks!
 
J

John Green

If you place a single quote in front of each cell entry ('), it will be treated as text and the replace will leave the entry as
text.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top