The reason we turn off calculation is in case the range in which we are deleting rows contains lots of formulas, if it does Excel may need to recalculate each time a row is deleted, slowing down the macro.
Whenever an event occurs that causes Excel to recalculate (for example a cell is changed, a VBA code calls for re calculation or anything else), the entire calculation process is carried out roughly as follows: 1. Orientation = xl Column Field Then Dim i As Long On Error Resume Next ' Needed to avoid getting errors when manipulating fields that were deleted from the data source. Screen Updating = True End Sub I get something along the lines of Sub Filter Pivot Table() With Active Sheet. You can then link all those cells which need to use the formula, to that single cell.So look at your spreadsheet, if you have a vlookup() that gets repeated over a 1000 cells and essentially all of them return the same value, take it out and put it in a single cell. Visible = False End With End Sub But I want all except K010 to become invisible The macro recorder ignores my select/deselect all clicks Sub Filter Pivot Field(Field As Pivot Field, Value) Application. Orientation = xl Column Field Then Dim i As Long On Error Resume Next ' Needed to avoid getting errors when manipulating Pivot Items that were deleted from the data source. This is because they only delete one row at a time! In some examples we turn off Calculation and Screenupdating. Screen Updating = True End With End Sub Sub Delete Blank Rows2() ' Deletes the entire row within the selection if _ some of the cells WITHIN THE SELECTION contain no data. Sub Show All Protected Pwd() Dim str Pwd As String str Pwd = "yourpassword" With Active Sheet . You can manually change a setting, to ungroup them, or use programming to turn the grouping on or off. Auto Filter Field:=i, _ Visibledropdown:=False Case Else Lst. Auto Filter Field:=i, _ Visibledropdown:=True End Select i = i 1 Next Application. Screen Updating = False Set ws L = Active Sheet Set Lst = ws L. Screen Updating = True End Sub Sub Copy Filtered Rows Only List1() Dim ws L As Worksheet Dim ws As Worksheet Dim rng As Range Dim rng2 As Range Dim Lst As List Object Application. If it tries to calculate a cell and finds that it is dependent on some other cell lower down the chain, it rearranges the chain to move that cell downwards.