Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Just My 2 cents:
Sub FixName() Dim Comma1 As String, StrChk As Variant, Cnt Dim LR As Long Application.ScreenUpdating = False LR = ActiveCell.SpecialCells(xlLastCell).Row Cnt = 1 Range("A1").Activate Comma1 = InStr(1, ActiveCell.Value, ",") Do Do StrChk = Mid(ActiveCell.Value, Comma1 - Cnt, 1) If IsNumeric(StrChk) = True Then Cnt = Cnt + 1 Else ActiveCell.Value = Left(ActiveCell.Value, Comma1 - Cnt) _ & " " & Mid(ActiveCell.Value, Comma1 + 2, Len (ActiveCell.Value)) End If Loop Until IsNumeric(StrChk) = False ActiveCell.Offset(1).Activate Cnt = 1 Comma1 = InStr(1, ActiveCell.Value, ",") Loop Until ActiveCell.Row LR End Sub HTH -----Original Message----- I have an issue I think can be solved with a Custom Cell Format. The problem is I'm not sure how to write the format. I have a Name column formated as General. The data looks like this in each cell: Smith1234, John How do I reformat the cell to knock out the numbers and leave me with Smith, John. Manually doing this would be consuming as I am trying to change about 4000 entries. Thanks in advance for any help! . |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Lock Cell Format - Allow copy and paste of data without format change | Excel Worksheet Functions | |||
cell format - remove cell format pattern without effecting colors | Excel Discussion (Misc queries) | |||
Can cell format come from and change with reference cell format | Excel Discussion (Misc queries) | |||
How do I copy data in single cell format to a merged cell format | Excel Discussion (Misc queries) |