Hi,

I think a loop can be avoided. See

[vba]On Error Resume Next
Range("c8:c27").SpecialCells(xlCellTypeFormulas, 16).EntireRow.Hidden = True
Range("c8:c27").SpecialCells(xlCellTypeConstants, 16).EntireRow.Hidden = True
On Error GoTo 0[/vba]
HTH