Try this
I don't know how to enumerate up to last row in a column, so i hard coded as 10, you should change it.Code:Sub test() For j = 1 To 10 ' replace 10 with the number of last row If Trim$(Cells(j, 1)) <> vbNullString Then ' it is not empty If Val(Cells(j, 1)) < 10 Then Cells(j, 1) = 10 End If End If Next End Sub





Reply With Quote