Hi all,
I am trying to work some code and am firstly I am encountering a problem and secondly I need some help with it.
The problem is that the first section of code on sheet "Validator" works correctly and autofilters the data then copies the filtered results into the "Combat" sheet. However the second part for sheet "Ships" is copying everything over and not just the autofiltered results - I can't figure our why for the life of me
As for the help I would like to know how I change the second part of the code so that the data from "Ships" is pasted directly beneath the data pasted from the "Validator" in the "Combat" sheet.
As always help greatfully appreciated - code below
I am trying to work some code and am firstly I am encountering a problem and secondly I need some help with it.
The problem is that the first section of code on sheet "Validator" works correctly and autofilters the data then copies the filtered results into the "Combat" sheet. However the second part for sheet "Ships" is copying everything over and not just the autofiltered results - I can't figure our why for the life of me
As for the help I would like to know how I change the second part of the code so that the data from "Ships" is pasted directly beneath the data pasted from the "Validator" in the "Combat" sheet.
As always help greatfully appreciated - code below
Code:
Sub CombatUpdaterTest()
Application.ScreenUpdating = False
Sheets("Validator").Select
ActiveSheet.Range("$A$7:$HV$500").AutoFilter Field:=63, Criteria1:=Sheets("Combat").Range("B4").Value
Selection.AutoFilter Field:=53, Criteria1:=""
Range("BD7:CX500").Select
Selection.Copy
Sheets("Combat").Select
Range("A700").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
Application.ScreenUpdating = True
Application.ScreenUpdating = False
Sheets("Ships").Select
ActiveSheet.Range("$A$6:$FC$10000").AutoFilter Field:=8, Criteria1:=Sheets("Combat").Range("B4").Value
Range("A6:AL500").Select
Selection.Copy
Sheets("Combat").Select
Range("A1200").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
Application.ScreenUpdating = True
End Sub