I have a code that works fine two days ago, but today I got this error message (Code execution has been interrupted)
And it breaks at the line of AutoFill
The weird thing is that when pressing F8, the code works line by line and with no problem. Any interpretation?
Code: Select all
With Sheet2 .Range("B1").Formula = "=LEN(RC[-1])" .Range("B1").AutoFill Destination:=.Range("B1", .Range("A1").End(xlDown).Offset(0, 1)) .Columns("A:B").Sort Key1:=.Range("B1"), Order1:=xlAscending, Key2:=.Range("A1"), Order2:=xlAscending .Columns(2).ClearContents End With