Question: my task is:

1) Select all cells in A row which contain values (done).
2) Text to Columns - example value 2017.01.01

```
Sub selectAndToColumns()
    Dim LR As Long
    LR = Range("A" & Rows.Count).End(xlUp).Row
    Range("A1:A" & LR).SpecialCells(xlCellTypeConstants, 23).Select
'2nd step
    Selection.TextToColumns Destination:=Range(A1), DataType:=xlDelimited, _
    TextQualifier:=xlDoubleQuote, ConsecutiveDelimiter:=False, Tab:=True, _
    Semicolon:=False, Comma:=False, Space:=False, Other:=True, OtherChar _
    :=".", FieldInfo:=Array(Array(1, 2), Array(2, 1), Array(3, 1))
End Sub

```

1 step is ok, but how can I use my selection instead of Range(A1) in 2nd step? Can I make a variable and how?

Answer: 
In python, a string is like a "instance of class str". To order to compare if the "content" within the input was a string, you can make something like...

```
a = input("Put something...")

if isinstance(a, str):
    print("Error caught, a string was given...")
else:
    print ("Now your number is", a, "and its type is" , type(a))

```
`eval` function does not really parse given string as number. It [evaluates string as a python expression](https://docs.python.org/2/library/functions.html#eval).

So the fact that `eval('2')` gives 2 is just a coincidence, because 2 is correct python expression that evaluates to number. 

So you shouldnt use `eval` to parse strings as numbers. Instead simply try parsing (con verting) it as integer, float and Decimal (in this order) and if you don't get error in any of your tries it means this is correct number of specified type. 

Answer posted by @jose-a shows how could it be done.