Thread: =clean(a1)
View Single Post
  #3   Report Post  
Posted to fj.comp.applications.excel,microsoft.public.excel,microsoft.public.excel.links,microsoft.public.excel.misc,microsoft.public.excel.programming
Dave Peterson[_3_] Dave Peterson[_3_] is offline
external usenet poster
 
Posts: 2,824
Default =clean(a1)

if it's just char(27) and char(7):
=SUBSTITUTE(SUBSTITUTE(A1,CHAR(27)," "),CHAR(7)," ")

And if there's a chance that those characters will be doubled up:
=TRIM(SUBSTITUTE(SUBSTITUTE(A1,CHAR(27)," "),CHAR(7)," "))

"news.verizon.net" wrote:

I want to get rid of special characters from A1. But I want it to be
replaced with space so there are 2 or 3 words:

A1

TESTchar(27)TEST1char(7)TEST2

After clean it should look like this

TEST TEST1 TEST2

Thanks.


--

Dave Peterson