hi,
i looking for a a vba codes or way on how can i remove all the character in the column and leave only the numbers.Thanks
hi,
i looking for a a vba codes or way on how can i remove all the character in the column and leave only the numbers.Thanks
can you give an example of string which needs to be proccessed?
try this:
[vba]
Sub number_collector()
Dim x, y As String
For i = 1 To 5
For j = 1 To Len(Cells(i, 1))
x = Mid(Cells(i, 1), j, 1)
If x > Chr(47) And x < Chr(58) Or x = Chr(44) Or x = Chr(46) Then
y = y + x
Else
If y <> "" Then
GoTo Jump:
End If
End If
Next j
Jump:
Cells(i, 2).Value = y
y = ""
Next i
End Sub
[/vba]
thanks a lot.Sorry can't reply you quickly...but the code does help..thanks again