title: In Excel VBA, the volatile Offset function is very slow. What is a alternative?
body: <p>I'm having a performance issue in my Excel macro. One particular piece of code runs really slow. I think the reason is the <code>Offset</code> function. I've found online that it is a volatile function which recalculates a lot.<br>
  The strange thing is that I use it as a VBA-function, so I can't figure out how it would affect performance as it never <em>needs</em> to be recalculated.</p>
  
  <p>This is how I use the offset function:</p>
  
  <pre><code>For i=0 To 10
   For P=0 To 3
    For T=0 To 3
      Range("C9").Offset(6 * i + T, P).Value = effect(i,P,T)
    Next
   Next
  Next
  </code></pre>
  
  <p>Is there a faster (nonvolatile?) alternative?</p>