title: Why do I keep getting a run error when using my macro?
body: <p>Hello I have a macro that I used on another project and trying to use it on this one. </p>
  
  <p>Currently I have two excel sheets (Excel sheet A and Excel sheet B) and have a macro that is supposed to take a certain range on a certain tab from Excel sheet A and then copy it on a certain tab in Excel sheet B.</p>
  
  <p>The macro is running fine up until a certain point towards the pasting part into Excel sheet B.</p>
  
  <p>The problem is right after ThisWorkbook.Activate:</p>
  
  <p>"Sheets("GTA800-1 Engine Hours").Select"</p>
  
  <p>The full code is listed below:</p>
  
  <pre><code>' open the source workbook and select the source sheet
  Workbooks.Open Filename:="D:My Documents\Fleet Data (Hrs, Aircraft flying, etc.)\updated_monthly_engine_hrs_97_03.xls"
  Sheets("PW150").Select
  
  ' copy the source range
  Sheets("PW150").Range("B2:G13").Select
  Selection.Copy
  
  ' select current workbook and paste the values 
  ThisWorkbook.Activate
  Sheets("GTA800-1 Engine Hours").Select
  Sheets("GTA800-1 Engine Hours").Range("B2:G13").Select
  Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:= _
  False, Transpose:=False
  
  ' close the source workbook
  Windows("updated_monthly_engine_hrs_97_03.xls").Activate
  ActiveWorkbook.Close
  </code></pre>