title: How to copy defined columns with defined number of rows from one Excel file to another
body: <p>I am new to VB and I am going to use it for Quick Test Pro (QTP). I am having a problem to copy data from one Excel to another Excel file with specific rows and columns. Here is the scenario:</p>
  
  <ol>
  <li>I have one Excel file with more than 20 rows. Let say 100 rows.</li>
  <li>I need to copy the first row, then the 2nd to 20th rows, then save it to a different file.</li>
  <li>I need to copy the first row, then the 21st to 41st rows, then save it to a different file.</li>
  <li>Then same thing for the rest. Until there is NO value on the last row.</li>
  </ol>
  
  <p>I need to copy the first row, because this is where the title/header is that I need.</p>
  
  <p>So far, this is what I did. But it only copies the single column and NOT the columns that I want:</p>
  
  <pre><code>Set objExcel = CreateObject("Excel.Application")
  Set objWorkbook1 = objExcel.Workbooks.Open("C:\Report\CMaxx_File1.xlsx")
  ObjExcel.Visible = True
  Set objWorkbook2 = objExcel.Workbooks.Open("C:\Report\CMaxx_File2.xlsx")
  objWorkbook1.Worksheets("Sheet1").Range("A1:A21").Copy
  objWorkbook2.Worksheets("Sheet1").Range("A1:A21").PasteSpecial 
  objWorkbook2.Save
  </code></pre>