Loop If statment. Can this work? Please check.
Posted by Jason on November 19, 2001 2:54 PM
I'm trying to get this sub to find the column number of the last column in a sheet that still has data. Is there a way to make this work? Am I just typing it wrong? Or does anyone know a better way to do this? Thanks
Count = 1
Do Until True
If Cells(1, 1 + Count) = Empty Then
C = Count - 1
Else: Count = Count + 1
End If
Loop