I need help fixing the loop below:
Dim Lastrow As Long
Dim i As Variant
Dim Valid As Boolean
Dim inputDec As Integer
Lastrow = Range("D65000").End(xlUp).Row
While Valid = False
i = InputBox("Ve kterém sloupci je datum? (A=1,B=2,C=3, atd..)", "Datum")
If IsNumeric(i) Then
Valid = True
Else
Valid = False
MsgBox ("Zadejte číslo sloupce! (A=1,B=2,C=3, atd..)")
End If
Wend
You can't enter letters etc.. But the problem is, that you can enter < 0. I was trying CODE like
If IsNumeric(i) And ">0" Then
But that doesnt work and ended in ERROR, can anyone help me please?