title: Excel macro formula adding quotes in formula causing vlookup to not work
body: <p>I am trying to add a formula to a cell. The macro is adding quotations around the cell range, which causes the cell to return the #name error.</p>
  
  <p>This is the code in the macro</p>
  
  <pre><code>Cells(1, 4).FormulaR1C1 = "=VLOOKUP(RC[-2],Contracts!A7:D30,3,FALSE)"
  </code></pre>
  
  <p>This is what the code returns in Excel after executing the macro.</p>
  
  <pre><code>=VLOOKUP(B4,Contracts!'A7':'D30',3,FALSE) 
  </code></pre>
  
  <p>Note that #name error disappears and the formula works, after I remove the quotations around the cell A7 and D30. </p>