title: How do you create a VLOOKUP using VBA 7.1?
body: <p>I would like to use VBA to update cells in an Excel Worksheet to VLOOKUP values in another worksheet in the same spreadsheet, this is in the likes of:</p>
  <pre><code>Cells(2, intColNum + 1).Formula = &quot;=VLOOKUP(R[0]C[-1],NameKeyIndex!C:D,2,FALSE)&quot;
  </code></pre>
  <p>However, when I run it in VBA, it goes into Excel like this:</p>
  <pre><code>=VLOOKUP(E3,NameKeyIndex!F:F:D,2,FALSE)
  </code></pre>
  <p>If I change it manually in Excel to <code>C:D</code> , it works, however is there a way it can <strong>not</strong> change my code and parse it as it is correctly?</p>