title: vba pass a group of cells as range to function
body: <p>I'm getting a group of cells and doing some calculations over them in function below.</p>
  
  <p>It works if I pass a range (with <code>:</code> sign) as first parameter, but it fails if I choose some cells as its range (<code>A1, A3, B6, B9</code>). It just gets first cell before comma as first parameter. But I want whole cells.</p>
  
  <p>What can I do? (except using strings for passing ranges)</p>
  
  <pre><code>Function calculateIt(Sessions As Range, Customers As Range) As Single
      ' calculate them...
  End Function
  </code></pre>
  
  <p><strong>One thing more:</strong> Is it possible to pass a group of ranges as a parameter? how?</p>