Public Function getNum(myField)
Dim S As String, l As Long, x As String
If Trim(myField & "") = "" Then
getNum = myField
Exit Function
End If
For l = 1 To Len(myField)
x = Mid(myField, l, 1)
If x >= "0" And x <= "9" Then
S = S & x
End If
Next
getNum = S
End Function