Well - I did it. Somehow.
In short, I checked across the horizontal up to the check cell, counting how many were in a row (resetting the count as soon as a non-like fruit was found). Then, I checked the horizontal AFTER the check cell. Instead of resetting the count after, I just stopped the loop.
By setting a variable to the start of the like-fruits' location, (this was also reset if a break was found BEFORE the check cell), I then had a start position and length of the consecutive like-fruits in the horizontal row.
By then repeating the above for the vertical, I had specific boundaries for the relevant horizontal and vertical valid cells.
By putting these values back into some For/Next loops, I replaced the relevant cells with a '9' value then continued to the 'scoring' routines.
Thanks for all your help, peeps. It's difficult when the program itself isnt in front of me :)
In short, I checked across the horizontal up to the check cell, counting how many were in a row (resetting the count as soon as a non-like fruit was found). Then, I checked the horizontal AFTER the check cell. Instead of resetting the count after, I just stopped the loop.
By setting a variable to the start of the like-fruits' location, (this was also reset if a break was found BEFORE the check cell), I then had a start position and length of the consecutive like-fruits in the horizontal row.
By then repeating the above for the vertical, I had specific boundaries for the relevant horizontal and vertical valid cells.
By putting these values back into some For/Next loops, I replaced the relevant cells with a '9' value then continued to the 'scoring' routines.
Thanks for all your help, peeps. It's difficult when the program itself isnt in front of me :)