Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I have a list of 1,400 names, most of which have 2 spaces preceding the name.
i would like to remove all the space. I read to put 2 spaces in the FIND & the following in REPLACE WITH: =--substitute(a1,char(160),"") but that didn't work possibly because it was posted in 2007. |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Find: press space bar twice
Replace with: <leave it blank Replace All "Starr" wrote: I have a list of 1,400 names, most of which have 2 spaces preceding the name. i would like to remove all the space. I read to put 2 spaces in the FIND & the following in REPLACE WITH: =--substitute(a1,char(160),"") but that didn't work possibly because it was posted in 2007. |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Hi
Look at the TRIM() function. Regards, Per On 9 Sep., 04:15, Starr wrote: I have a list of 1,400 names, most of which have 2 spaces preceding the name. *i would like to remove all the space. *I read to put 2 spaces in the FIND & the following in REPLACE WITH: =--substitute(a1,char(160),"") *but that didn't work possibly because it was posted in 2007. |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
A couple ideas:
Sub Remove_CR_LF() With Selection ..Replace What:=Chr(160), Replacement:=Chr(32), _ LookAt:=xlPart, SearchOrder:=xlByRows, MatchCase:=False ..Replace What:=Chr(13) & Chr(10), Replacement:=Chr(32), _ LookAt:=xlPart, SearchOrder:=xlByRows, MatchCase:=False ..Replace What:=Chr(10), Replacement:=Chr(32), _ LookAt:=xlPart, SearchOrder:=xlByRows, MatchCase:=False End With End Sub Sub tic_killer() Set rr = ActiveSheet.UsedRange.SpecialCells(xlCellTypeConst ants, xlTextValues) For Each r In rr If r.PrefixCharacter = "'" Then r.Value = r.Value End If Next End Sub HTH, Ryan--- -- Ryan--- If this information was helpful, please indicate this by clicking ''Yes''. "Per Jessen" wrote: Hi Look at the TRIM() function. Regards, Per On 9 Sep., 04:15, Starr wrote: I have a list of 1,400 names, most of which have 2 spaces preceding the name. i would like to remove all the space. I read to put 2 spaces in the FIND & the following in REPLACE WITH: =--substitute(a1,char(160),"") but that didn't work possibly because it was posted in 2007. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Why can i not delete cells in my workbook? | Excel Discussion (Misc queries) | |||
Delete spaces | Excel Discussion (Misc queries) | |||
delete cells from one workbook to another | Excel Worksheet Functions | |||
removing unnecessary spaces from multiple cells | Excel Worksheet Functions | |||
delete spaces | Excel Worksheet Functions |