title: Excel VBA, How to select rows based on data in a column?
body: <pre><code>Sub SelectAllReleventText()
  Do While Range(“A1”).Offset(1, 6) &lt;&gt; Empty
  Rows(ActiveCell.Row).Select
  ActiveCell.Offset(1, 0).Select
  Loop
  End Sub
  </code></pre>
  
  <p>Here is my script, I've been told it doesn't do what it is meant to, which I expected since this was my first attempt. I am coming up with a variable not defined error. I thought I defined the  variable, but I guess it wasn't specific enough for Excel VBA. </p>
  
  <p>This is what I am attempting to do. </p>
  
  <ol>
  <li>In Workbook 1, On B6 there is an alphanumeric name, I want that row to be selected.</li>
  <li>Go down one row, if there is text there select that row.</li>
  <li>Continue till text is no longer prevalent. </li>
  <li>Copy selected rows.</li>
  <li>Paste into another workbook (Workbook2), into tab 1, starting on row 2, since row 1 has headers.</li>
  </ol>
  
  <p>Thanks in advance. Just a heads up, I am using the Options Explicit in my VBA because I was told it was the "right way to do thing"...</p>