problems with autofilter

sam_01

New member
Local time
Yesterday, 17:54
Joined
Nov 19, 2007
Messages
8
hello freinds,
i have 2 sheets in one workbook
i am applying the autofilter for sheet1 through the value in the cells of sheet2

i am able to reterive the value of 3 fields and my problem lies from here ..

here is my my code:

Public Sub Tester02A()
Dim DataSh As Worksheet
Dim CritSh As Worksheet
Dim n As Integer
Dim i As Integer
With ActiveWorkbook
Set DataSh = .Sheets("version")
Set CritSh = .Sheets("table")
End With

DataSh.ShowAllData
DataSh.Cells.AutoFilter field:=1, Criteria1:="=" & CritSh.Range("A2").Value
DataSh.Cells.AutoFilter field:=2, Criteria1:="=" & CritSh.Range("B2").Value
DataSh.Cells.AutoFilter field:=3, Criteria1:="=" & CritSh.Range("C2").Value
:mad:
' from here i need to search the value of the & critsh.range(d2) and i am unable to search the value in the column headers .
:mad:
End Sub

any thoughts would be appreicated
 

Users who are viewing this thread

Back
Top Bottom