title: Excel VBA SUM Formula Displaying in Cell
body: <p>I have the following routine called from a procedure</p>
  
  <pre><code>Sub DoTotals()
  
    With ActiveSheet.Cells(Rows.Count, "F").End(xlUp)(2, 1)
      .Formula = "=SUM(F2:" &amp; .Offset(-1, 0).Address &amp; ")"
    End With
  
  End Sub
  </code></pre>
  
  <p>The result displayed in the cell is not the result of the summation, but 
  <code>=SUM(F$1:$F2)</code></p>
  
  <p>I've used the same routine in other Excel docs and it properly returned the sum - not in this one, however.</p>