View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
Nader Nader is offline
external usenet poster
 
Posts: 44
Default How to filter data in another sheet

hi
thanks for the feedback.

If this post was helpfull, please remember to click on the ''''YES''''
button at the bottom of the screen.
Thanks,

nader

"AKS" wrote:

Hi Nader,

Thanks a ton for your support and it is working perfectly now.

Warm regards,
AKS

"nader" wrote:

Hi,
you are welcome,
If your item cods in column H and dates in column F in sheet1, try this
macro, you can change Field numbers as your columns number.

Sub filterme()

'On Error Resume Next

Sheets("sheet1").Select
Selection.AutoFilter Field:=8, Criteria1:="=" & Range("Sheet2!A1").Value
Selection.AutoFilter Field:=6, Criteria1:="=" & Range("Sheet2!A2").Value,
Operator:=xlAnd _
, Criteria2:="<=" & Range("Sheet2!A3").Value


End Sub

If you have problem, try in format cell by 'general' , in cell A1 & A2

please feedback;

kind regards,
Nader

"AKS" wrote:

Hi,
Thanks for your quick response.
My problem is that I have 3 criterion

in A1 item Code
in A2 From Date
in A3 To Date

Please help!!

Best regards,
AKS

"nader" wrote:

hi AKS
I use this macro for same question:

Sub FilterMe()
On Error Resume Next

Sheets("Sheet1").Select

Selection.AutoFilter Field:=6, _
Criteria1:="=" & Range("Sheet2!A1").Value

End Sub
you must put particular item in A1
it may be help you

"AKS" wrote:

I have huge data in sheet1 with column headers and I would like to filter few
data in sheet2 matching with queries like data of a particular item between
two dates.

Can anybody help me out?