methode2404
New Member
- Joined
- Sep 3, 2018
- Messages
- 30
Hi,
It doesn't work,
It should filter the data in sheet(data) with the criteria in "A4:A42" when i input RngSun
It should filter the data in sheet(data) with the criteria in "B4:B40" when i input RngMon.....
Where is the mistake ???
Sub testautofilter()
Dim RngSun As Range
Dim RngMon As Range
Dim RngTues As Range
Dim RngWed As Range
Dim RngThurs As Range
Dim RngFri As Range
Set RngSun = Sheets("sevk").Range("A4:A42")
Set RngMon = Sheets("sevk").Range("B4:B40")
Set RngTues = Sheets("sevk").Range("C4:C39")
Set RngWed = Sheets("sevk").Range("D4:D39")
Set RngThurs = Sheets("sevk").Range("E4:E39")
Set RngFri = Sheets("sevk").Range("F4:F23")
INPPP = InputBox("enter your choice")
ActiveSheet.Range("$A$1:$L$100").AutoFilter field:=5, Criteria1:=INPPP, Operator:=xlFilterValues
End Sub
It doesn't work,
It should filter the data in sheet(data) with the criteria in "A4:A42" when i input RngSun
It should filter the data in sheet(data) with the criteria in "B4:B40" when i input RngMon.....
Where is the mistake ???
Sub testautofilter()
Dim RngSun As Range
Dim RngMon As Range
Dim RngTues As Range
Dim RngWed As Range
Dim RngThurs As Range
Dim RngFri As Range
Set RngSun = Sheets("sevk").Range("A4:A42")
Set RngMon = Sheets("sevk").Range("B4:B40")
Set RngTues = Sheets("sevk").Range("C4:C39")
Set RngWed = Sheets("sevk").Range("D4:D39")
Set RngThurs = Sheets("sevk").Range("E4:E39")
Set RngFri = Sheets("sevk").Range("F4:F23")
INPPP = InputBox("enter your choice")
ActiveSheet.Range("$A$1:$L$100").AutoFilter field:=5, Criteria1:=INPPP, Operator:=xlFilterValues
End Sub