Excel: Counting Consecutive Texts

Hello, I really need help figuring out the formula for an assignment. On my spreadsheet, I have the monthly status of projects in action. From cells H28-S28, the cells are labeled either "on track", "off-track", "at risk" and "completed". I want to count the amount of consecutive times the projects were labeled "off-track" or "at risk" consecutively. For instance:

On Track On Track On Track On Track On Track At Risk At Risk At Risk At Risk Off Track Off track Off Track
The answer here would be 7 because "at risk" and "off track" were the consecutive statuses for seven months straight. Please help!

This question generated 41 answers. To proceed to the answers, click here.

This thread is current as of June 24, 2014.

For more resources for Microsoft Excel