ella1327
08-28-2020, 11:55 PM
Hi everyone,
I need some help with my macro. Currently, it is only picking up on the criteria in the first 3 columns. I need it to run on my entire worksheet without having to reformat and put all of my data under the first three columns. I want to be able to keep the format as is but still have the macro pick up on the criteria in all the columns. Is this possible to do? I'm new to the macro world so please let me know if something is unclear. Thank you in advance for your help!
Gabriella
Here is the code I'm using:
Sub Test()
'
' Test Macro
'
' Keyboard Shortcut: Ctrl+Shift+T
'
Application.CutCopyMode = False
Application.CutCopyMode = False
Application.CutCopyMode = False
Sheets("Operations").Range("A4:N34").AdvancedFilter Action:=xlFilterCopy, _
CriteriaRange:=Sheets("Operations").Range("V4:V6"), CopyToRange:=Range( _
"A1:B1"), Unique:=False
End Sub
I need some help with my macro. Currently, it is only picking up on the criteria in the first 3 columns. I need it to run on my entire worksheet without having to reformat and put all of my data under the first three columns. I want to be able to keep the format as is but still have the macro pick up on the criteria in all the columns. Is this possible to do? I'm new to the macro world so please let me know if something is unclear. Thank you in advance for your help!
Gabriella
Here is the code I'm using:
Sub Test()
'
' Test Macro
'
' Keyboard Shortcut: Ctrl+Shift+T
'
Application.CutCopyMode = False
Application.CutCopyMode = False
Application.CutCopyMode = False
Sheets("Operations").Range("A4:N34").AdvancedFilter Action:=xlFilterCopy, _
CriteriaRange:=Sheets("Operations").Range("V4:V6"), CopyToRange:=Range( _
"A1:B1"), Unique:=False
End Sub