Hello -
I have created a basic copy and paste macro that was working fine, but when I went to expand the amount of sheets I started receiving an Automation Error: Object has disconnected from its client message:
I run this code over about 30 times with "Daffy, Duck" the only thing changing, almost at the end I get the error.
Any help is greatly appreciated.
Here is the code:
I have created a basic copy and paste macro that was working fine, but when I went to expand the amount of sheets I started receiving an Automation Error: Object has disconnected from its client message:
I run this code over about 30 times with "Daffy, Duck" the only thing changing, almost at the end I get the error.
Any help is greatly appreciated.
Here is the code:
Code:
Sub Duck()
'
'
Application.CutCopyMode = False
Application.ScreenUpdating = False
Sheets("Pivot Data Sheet").Select
ActiveSheet.Range("$A$1:$BD$184").AutoFilter Field:=12, Criteria1:="Fail"
ActiveSheet.Range("$A$1:$BD$184").AutoFilter Field:=16, Criteria1:="Daffy, Duck"
ActiveSheet.Range("A2:BD50000").Copy Destination:=Sheets("Daffy, Duck").Range("A2")
ManagerSortedData = Empty
Application.CutCopyMode = False
Sheets("Pivot Data Sheet").Select
ActiveSheet.ShowAllData
End Sub