Results 1 to 2 of 2

Thread: filtering greater than and less than < x >

  1. #1

    Question filtering greater than and less than < x >



    Register for a FREE account, and/
    or Log in to avoid these ads!

    Hi

    I am having trouble filtering greater than in one range and less than in another range at the same time. If i separate them, they work separately but not at the same time. What is going on and can anyone help. Here is the code below.

    Code:
    Sub Filtergreater()
    
    Sheets("FolderSort").Select
        ActiveSheet.AutoFilterMode = False
        Range("I4:I368").AutoFilter field:=1, Criteria1:=">" & Sheets("FrontPage").Range("E17").Value
        Range("J4:J368").AutoFilter field:=1, Criteria1:="<" & Sheets("FrontPage").Range("K17").Value
    
    End Sub

    Thanks in advance.
    Last edited by Bob Phillips; 2014-04-14 at 04:34 PM. Reason: Added VBA tags

  2. #2
    Code:
    Sub Filtergreater()
    
    Sheets("FolderSort").Select
        ActiveSheet.AutoFilterMode = False
        Range("I4:J368").AutoFilter field:=1, Criteria1:=">" & Sheets("FrontPage").Range("E17").Value
        Range("I4:J368").AutoFilter field:=2, Criteria1:="<" & Sheets("FrontPage").Range("K17").Value
    
    
    End Sub

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •