Number Stored as Text.

  • Thread starter Thread starter musa.biralo
  • Start date Start date
M

musa.biralo

Hi,
i looked at the posts but could not find exact one. I have a column,
say A:A filled with numbers and text stored as text. i want the
conversion only to the numbers not to the text. Here is an example

1000
2000
2000A
3000

All these are stored as text and i want to convert only numeric
ones..I tried to use "ISNUMERIC" but did not worke as number were
stored as text.

Please help.

(Recording Macro is not helping)

musa.biralo
 
Isnumeric will return true for number stored as text, so it should work.

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)
 
Sub fixum()
Set r = Range("A:A").SpecialCells(xlCellTypeConstants)
For Each rr In r
If IsNumeric(rr.Value) Then
rr.NumberFormat = "General"
rr.Value = rr.Value
End If
Next
End Sub
Sub fixum()
Set r = Range("A:A").SpecialCells(xlCellTypeConstants)
For Each rr In r
If IsNumeric(rr.Value) Then
rr.NumberFormat = "General"
rr.Value = rr.Value
End If
Next
End Sub
 
Back
Top