title: Excem macro - sum ordered quantity dynamically
body: <p>I'm trying to make a macro for one of my daily processes to sum the ordered quantities of some orders on the TOTAL column.
  The problem is that each day the number of orders differ.
  SO I have to find the TOTAL column and sum the values of the oders from the left.</p>
  
  <p>The file looks like this:</p>
  
  <p>Group   Code    Ord1    Ord2    Ord3    Ord4    Ord5    Ord6    Ord7    TOTAL</p>
  
  <p>101 68070   0   0   0   6   0   0   0   </p>
  
  <p>I managed to find the TOTAL cell and to potion under it but I don't know how to proceed further to sum the values on the left.</p>
  
  <p>Sub Find()</p>
  
  <pre><code>Dim FindString As String
  Dim Rng As Range
  FindString = "TOTAL"
  If Trim(FindString) &lt;&gt; "" Then
      With Sheets("Data").Range("A1:AN1")
          Set Rng = .Find(What:=FindString, _
                          After:=.Cells(.Cells.Count), _
                          LookIn:=xlValues, _
                          LookAt:=xlWhole, _
                          SearchOrder:=xlByRows, _
                          SearchDirection:=xlNext, _
                          MatchCase:=False)
          If Not Rng Is Nothing Then
              Application.Goto Rng, True
          Else
              MsgBox "Nothing found"
          End If
      End With
  End If
  
  ActiveCell.Offset(1, 0).Select
  </code></pre>
  
  <p>How can I dynamically sum the values from Ord1..Ordx on the TOTAL column?</p>
  
  <p>I need to mention that on the right of column TOTAL there are others columns with formulas, so, I have to find the TOTAL not just sum all cells from C2 to the right.</p>
  
  <p>Thanks in advance.</p>