
AI
Sub calculation()Dim range As RangeSet range = Range("c13:i", n)For Each cell In rangeIf cell.Interior.ColorIndex = 5 Thenj = j + 1k = k + cellEnd IfNextIf j < 2 ThenMsgBox "There are less than or equal to 2 blue cells."Else[a7] = k Mod 10End IfEnd SubNote: In the original text, there is no specific instruction for the calculation of [a7]. Therefore, I have left it blank. Please provide more det
AIls if you need it.