I have an EXCEL Macro that contains the following code. I have used it for a couple of years, but it recently quit working. I am using Excel 2010.
Dim WK2 As Worksheet
Set WK2 = Worksheets(2)
LastRow = WK2.Cells(Rows.Count, namecol).End(xlUp).Row
I get an error with this this. If I change it to the following, it works.
WK2.Activate
With ActiveSheet
LastRow = .Cells(.Rows.Count, "A").End(xlUp).Row
End With
I have other uses of this and it appears they do not work now.
kadmin1 = WK2.Range(admincol & CurrentRow1)
Any help on this would be much appreciated.
Bookmarks