Hi all,
I'm quite new to this so please don't flame me if I've posted in the wrong area.
I'm seeking some advice/help with regards to the below
Basically I'm trying to have the macro autofilter specific date ranges determined by a value (1,2,3,4,5 etc...) from the main worksheet (for this post I have called it MACRO).
If anyone has any ideas could they please let me know?
Dim x As String
Dim dDate As Date
Dim strDate As String
Dim lDate As Long
dDate = DateSerial(Year(Date), Month(Date), Day(Date))
lDate = dDate
x = not sure about here but something like ? Sheets(MACRO).Range("A1").Value
Range("A1").Select
Sheets("WORKING SHEET").Select
Rows("1:1").Select
ActiveSheet.Range("$A$1:$AP$1912").AutoFilter Field:=10, Criteria1:=">" & lDate + x, Operator:=xlAnd
Rows("2:2").Select
Any help would be greatly appreciated!
Thanks in advance
mpham168
I'm quite new to this so please don't flame me if I've posted in the wrong area.
I'm seeking some advice/help with regards to the below
Basically I'm trying to have the macro autofilter specific date ranges determined by a value (1,2,3,4,5 etc...) from the main worksheet (for this post I have called it MACRO).
If anyone has any ideas could they please let me know?
Dim x As String
Dim dDate As Date
Dim strDate As String
Dim lDate As Long
dDate = DateSerial(Year(Date), Month(Date), Day(Date))
lDate = dDate
x = not sure about here but something like ? Sheets(MACRO).Range("A1").Value
Range("A1").Select
Sheets("WORKING SHEET").Select
Rows("1:1").Select
ActiveSheet.Range("$A$1:$AP$1912").AutoFilter Field:=10, Criteria1:=">" & lDate + x, Operator:=xlAnd
Rows("2:2").Select
Any help would be greatly appreciated!
Thanks in advance
mpham168