I test this code to loop if one date is into my array.
with the example on the column A, nothing problem,
the result message is 3 and in the immediate window I saw (01/01/2015,06/01/2015,02/02/2015)
to test some case when only 1 day is into array, I delete the 2 day (A3,A4) like column C.
the result message is 1 but i received error on rule For Each i In arfest (error runtime 13, type not corresponding)
and if I delete also the value on A2, I retrieve the msg with 1 and the same error previous example.
Sub dada_click()
Dim arfest As Variant
Dim i As Variant
UR = Sheets("Fest").Cells(Rows.Count, 1).End(xlUp).Row
If UR < 2 Then UR = 2
arfest = Sheets("Fest").Range("A2:A" & UR)
MsgBox (Application.CountA(arfest))
For Each i In arfest
Debug.Print i
Next i
End Sub
What's wrong?!?!? thank
