title: Application.WorksheetFunction.Sum Runtime error 424
body: <p>I am trying to use this code to hide rows from row 15 to row 59 if the 
  <code>sumi</code> from B15 to K15 using <code>i</code> to index the rows from 15 to 59.  SEE BELOW</p>
  
  <p>On the <code>sumi</code> line below I get a </p>
  
  <blockquote>
    <p>runtime error 424 "Object Required" </p>
  </blockquote>
  
  <p>and I cannot see where the problems is.  I am sure it is something simple.  Any help would be greatly appreciated.</p>
  
  <pre><code>Dim i As Integer
  Dim sumi As Single
  
  i = 15
  
  Do Until i = 56
       StartRow = i
       EndRow = i
  
       Application.EnableEvents = True
  
       sumi = Aplication.WorksheetFunction.Sum(Range("B" &amp; i &amp; ":K" &amp; i))
  
       Application.EnableEvents = False
  
       If sumi = "0" Then
            Rows("StartRow:RowEnd").EntireRow.Hidden = True
       ElseIf sumi &gt; 0 Then
            Rows("StartRow:RowEnd").EntireRow.Hidden = False
            MsgBox " sumi = " &amp; sumi
       End If
       Application.EnableEvents = True
       i = i + 1
  Loop
  </code></pre>