title: Excel VBA: How to find max/min of a range while ignoring error cells
body: <p>How can I use VBA in Excel to determine the max/min of a range that contains error cells such as <code>#N/A</code> or empty cells?  I know this is a fairly easy task to conquer with Excel array formulas using something like<br>
   <code>=MIN(IF(A1:A10="#N/A"))</code></p>
  
  <p>but I would very much like to accomplish this using VBA.  </p>
  
  <p>I'm dealing with several thousand lines of data so the speediest solution would be preferred.</p>
  
  <p>Thank you so much!</p>