title: End(xlToRight) sends me to the last colum--XFD i want to go to the next column, not the last column
body: <p>In Excel VBA I am comparing two columns.  If the the value in column H appears in column B I want to past a value in the next blank cell to right of column H.</p>
  
  <pre><code>For Each ThisCell1 In Range("H5:H" &amp; Cells(Rows.Count, "H").End(xlUp).Row)
      'This is the range of cells to check
          For Each ThisCell2 In Range("B5:B" &amp; Cells(Rows.Count, "B").End(xlUp).Row)
          'This is the range of cells to compare
      If ThisCell1.Value = ThisCell2.Value Then
              ThisCell1.End(xlToRight).Value = Range("B4")
  </code></pre>
  
  <p>My code puts B4 in column XFD, but I want it in column I, J or K.  What am I doing wrong.</p>