A Row Count component appears in a Data Flow task, not a Foreach task. So, I assume you have a Data Flow task in the Foreach task.
The Row Count component only captures the count for the current run of the Data Flow task. There isn't an inherent way to capture the cumulative total; so, you will have to do it yourself. One way is to create another variable to store the cumulative total and a Script task that adds the Row Count variable to the cumulative count variable. The new Script task would appear in the Foreach task and follow the Data Flow task.