title: Copy rows from multiple sheets into one sheet
body: <pre><code>Public Sub SubName()
  Dim ws As Worksheet
  Dim iCounter As Long
  Dim wso As Worksheet
  Dim rw As Long
  Dim lastrow As Long
  
  Set wso = Sheets("Master")
  
  For Each ws In ActiveWorkbook.Worksheets
      If ws.Name Like "*" &amp; "danger" &amp; "*" Then
      ws.Select
      lastrow = ws.Cells(Rows.Count, 4).End(xlUp).Row
              For iCounter = 2 To lastrow
                  If ws.Cells(iCounter, 8) &lt; 0.15 And ws.Cells(iCounter, 8) &gt; -0.1 Then
  
                      ws.Cells(iCounter, 8).EntireRow.Copy
  
                      rw = wso.Cells(wso.Rows.Count, "A").End(xlUp).Row + 1
                      wso.Cells(rw, 1).PasteSpecial Paste:=xlPasteAll
  
                  End If
              Next iCounter
  
      End If
  Next ws
  End Sub
  </code></pre>
  
  <p>This is what the code does:</p>
  
  <ol>
  <li>Look through all sheets, find sheets with text "danger"</li>
  <li>With sheets named "danger*", go through column H and copy the entire row if criteria is met</li>
  <li>Paste the entire row onto master sheet</li>
  </ol>
  
  <p>I believe the code is working fine up to the point where I need it to paste onto the master sheet. The problem i'm getting is that it simply pastes over the same row on the master sheet, instead of going row+1. </p>
  
  <p>The end result is there's only one row showing on the master sheet and it's the last row in the iteration that's to be pasted.</p>
  
  <p>Any help is appreciated!</p>
  
  <p><a href="https://i.stack.imgur.com/ds05x.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ds05x.jpg" alt="enter image description here"></a></p>