convert text to numbers

G

Gary B

Have copied and pasted a column of numbers to an excel 2003 worksheet. When I
try to sum then I get a zero as the sum. Have tried to use the =Value(A1)
formula to read to the next col as a number but get the #VALUE! Error. Must
be an easy way to do this, any ideas?
 
E

Eduardo

Hi Gary,
maybe you have blank spaces that you cannot see enter in another column

=trim(A1)

then do copy of this column, go to A1 and paste special, values
 
×

מיכ×ל (מיקי) ×בידן

Only if the two previous suggestions do not help you - try using User Defied
Function:
Press ALT+F11 and paste the following code into a Module(!)
To resolve the "pure" number from cell A1, type in cell B1: =StripNumber(A1)
-----------------------------------------------------
Function StripNumber(stdText As String)
stdText = Trim(stdText)
For C = 1 To Len(stdText)
If IsNumeric(Mid(stdText, C, 1)) Then strg = strg & Mid(stdText, C, 1)
Next
StripNumber = strg * 1
End Function
 
Top