Excel move number to left and delete number in Column C:C

SteveD 685 Reputation points
2026-10-31T04:16:18.92+00:00

Hello From Steve

Objective please Excel move number from C:C to B:B and delete number in Column C:C

The below moves Numbers to the Left Cell

Can the below be modified to leave text only

From

12345Defective

to

Defective

Thank you

Sub Move_Numerals_to_the_Left_Cell()

Dim cell As Range, num As String, ch As String, i As Long

For Each cell In Selection

    num = ""

    For i = 1 To Len(cell.Value)

        ch = Mid(cell.Value, i, 1)

        If IsNumeric(ch) And ch <> " " Then

            num = num & ch

        End If

    Next i

    ' Write result to the column on the left

    cell.Offset(0, -1).Value = num

Next cell
```End Sub

Microsoft 365 and Office | Excel | For home | Windows
0 comments No comments

Answer accepted by question author
Barry Schwarz 6,431 Reputation points
2026-10-31T06:00:44.02+00:00

The following macro will store the text without the leading digits in the cell to the left.

Sub test()
Dim cell As Range
Dim num As String
Dim ch As String
Dim i As Long
Dim j As Long
    
    For Each cell In Selection
        num = ""
        j = Len(cell.Value)
        
        For i = 1 To j
            ch = Mid(cell.Value, i, 1)
            If Not IsNumeric(ch) Or ch = " " Then
                ' Write result to the column on the left
                cell.Offset(0, -1).Value = Mid(cell.Value, i, j - i + 1)
                i = j + 1             'Terminate the loop
            End If
        Next i
        
    Next cell
End Sub

You can add a step to clear the original cell if you desire. If the text contains all digits, the cell to the left is untouched.

Was this answer helpful?

2 people found this answer helpful.

0 additional answers

Sort by: Oldest

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.