title: Efficient way to delete rows (Multiple criterias) VBA
body: <p>I have a sheet where in Col A there is a String A and Col B consists of String B. </p>
  
  <p>I want to keep rows with the Word 'Begründung' in Col A and 'Nein' in Col B.</p>
  
  <p>I am using the following code found from these sources <a href="https://stackoverflow.com/questions/16901436/efficient-way-to-delete-entire-row-if-cell-doesnt-contain">Efficient way to delete entire row if cell doesn&#39;t contain &#39;@&#39;</a> &amp; <a href="https://stackoverflow.com/questions/13614997/delete-row-based-on-search-key-vba">Delete Row based on Search Key VBA</a></p>
  
  <pre><code>Sub KeepOnlyAtSymbolRows()
      Dim ws As Worksheet
      Dim rng As Range
      Dim lastRow As Long
  
      Set ws = ActiveWorkbook.Sheets("Sheet1")
  
      lastRow = ws.Range("A" &amp; ws.Rows.Count).End(xlUp).Row
  
      Set rng = ws.Range("A1:A" &amp; lastRow)
  
      ' filter and delete all but header row
      With rng
          .AutoFilter Field:=1, Criteria1:="&lt;&gt;*Begründung*"
          .Offset(1, 0).SpecialCells(xlCellTypeVisible).EntireRow.Delete
      End With
  
      ' turn off the filters
      ws.AutoFilterMode = False
  End Sub
  </code></pre>
  
  <p>I want to add another criteria for the Col B. Wherever in Col B 'Nein' is encountered that row is kept and the rest is deleted but at the same time 'Begrüundung in Col A is kept and the rest is deleted. </p>
  
  <p>In other words wherever the words 'Begründung' and 'Nein' is encountered in the sheet those rows are kept and the rest is deleted. </p>
  
  <p>I would really be grateful if any of you could help.</p>