Hudson Andrew
New Member
- Joined
- Sep 28, 2016
- Messages
- 31
Hi all ,
I have macro that does quick filter on column "N" and look for the dollar value >=5000
and copy the records and past in next sheet , now i wanted is if my filter column does not have dollar value of >=5000
macro should terminate .
below is the macro for your refernce .
I have macro that does quick filter on column "N" and look for the dollar value >=5000
and copy the records and past in next sheet , now i wanted is if my filter column does not have dollar value of >=5000
macro should terminate .
below is the macro for your refernce .
Code:
Sub sixtydays()'
' sixtydays Macro
'
'
Range("M1").Select
Selection.AutoFilter
Range("N1").Select
ActiveSheet.Range("$A$1:$P$904").AutoFilter Field:=14, Criteria1:=">=5000" _
, Operator:=xlAnd
Range("A1").Select
Selection.CurrentRegion.Select
Selection.SpecialCells(xlCellTypeVisible).Select
Selection.Copy
ActiveSheet.Next.Select
ActiveSheet.Next.Select
ActiveSheet.Next.Select
ActiveSheet.Next.Select
ActiveSheet.Previous.Select
Range("A1").Select
ActiveSheet.Paste
Cells.Select
Selection.Columns.AutoFit
Range("A1").Select
ActiveSheet.Previous.Select
ActiveSheet.Previous.Select
ActiveSheet.Previous.Select
Range("A1").Select
Application.CutCopyMode = False
Selection.AutoFilter
Range("A1").Select
End Sub
any inputs are appricated .