Remove partial data from a cell

  • Thread starter Thread starter RodG
  • Start date Start date
R

RodG

I have a list of codes like the following:
12345-1610
64321-1610
etc.
The codes are in a single cell and I need a formula to remove th
"-1610" part. Any help would be greatly appreciated.

Thank
 
Rod, select the cells and Edit > Replace. Find what: -1610. Replace with:
[leave blank]. Click Replace once or twice to test the result. Click Replace
All to do them all
 
Thank you for your response. Can this be done automatically with
formula? The data being imported will be different each time and I d
not want to have to sort, find & replace each time?

Thanks again
 
Rod, a formula like this will do it: =LEFT(A1,FIND("-",A1)-1), followed by
Edit > Copy > Edit > Paste Special > Values > OK.

But you'll probably want a macro or VBA solution. Let's see if "Unresolved"
tempts someone to post one.
 
Thank You!!! That works like a charm. I will be interested to see i
anyone posts a macro solution
 
Back
Top