title: VBA : How to count number of rows in filtered column?
body: <p>I have an Excel sheet with four columns of data. </p>
  
  <p>I have applied auto filter to second column. Now I want to count the number of rows after applying filter.</p>
  
  <p>Here is the code used to apply auto filter:</p>
  
  <pre><code>Sub filtered_row_count()
  
  Sheets("Sheet1").Select
  row_count = Application.CountA(Range("B:B")) - 1 'Subtract the header
  
  Selection.AutoFilter Field:=2, Criteria1:="cat"
  
  End Sub
  </code></pre>
  
  <p>How to find the number of rows after this filter has been applied?</p>