title: excel vba call subroutine with variables
body: <p>I defined the following subroutine:</p>
  
  <pre><code>Sub EnterCellValueMonthNumber(cells As range, number As Integer)
  
  range(cells).Select
  ActiveCell.FormulaR1C1 = number
  
  End Sub
  </code></pre>
  
  <p>When I call the subroutine like this:</p>
  
  <pre><code>EnterCellValueMonthNumber ("N23:Q23",1)
  </code></pre>
  
  <p>I get the following error message:</p>
  
  <pre><code>Compile error Expected: =
  </code></pre>
  
  <p>I have no idea why I get this message. Does anyone know what I am missing?</p>