Hello nur2544,
Or you could change your code to:
Also see the "Please consider" note at the bottom of this post.![]()
Sub EnterFormula() Sheets(Array("i6", "i7", "i8", "i9", "i10", "i11", "i12", "i13", "i14", "i15")).Select Sheets("i6").Activate Range("AB6").Select ActiveCell.Formula = "=IF(COUNT(BD6:BL6)=0,"""",SUM(BD6:BL6)/9)" Sheets("i6").Select End Sub
![]()
Bookmarks