title: Run-time Error '13' Type Mismatch IF value = Then Statement loop
body: <p>Basically what I'm doing is I have data in columns A-I and I'm trying to copy out data [Columns D-G] by their value in D. In this loop I'm looking for when the entry in D says "1CME Cash-Settled Butter". </p>
  
  <p>I then starting in column K (=11) I paste it. Then I stack the rows. </p>
  
  <p>The loop starts over and starts looking for a different value. </p>
  
  <p>My problem is that I've ran the code fine for many runs. I haven't changed the code since, but now I'm getting Run-Time Error Type '13' Mismatch. Is there someway to fix this or write new code? </p>
  
  <p>I'm just learning VBA!</p>
  
  <p>Thanks!</p>
  
  <pre><code>iRow = 2
  For Each i In Range("D2:D200")
      If i.Value = "1CME Cash-Settled Butter" Then
          Range(i.Offset(0, 0), i.Offset(0, 3)).Copy
          Cells(iRow, 11).PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,   SkipBlanks:=False, Transpose:=False
          iRow = iRow + 1
      End If
  Next i
  
  iRow = 30
  For Each i In Range("D2:D200")
      If i.Value = "-1CME Cash-Settled Butter" Then
          Range(i.Offset(0, 0), i.Offset(0, 3)).Copy
          Cells(iRow, 11).PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
              :=False, Transpose:=False
          iRow = iRow + 1
      End If
  Next i
  </code></pre>