The following code copies several rows of formulas and pastes the values in the row above.
Dim vSourceCells As Integer Dim vDestinationCells As Integer With Application .ScreenUpdating = False .DisplayAlerts = False End With 'Copies income section For vSourceCells = 12 To 42 Step 3 vDestinationCells = vSourceCells - 1 Range(Cells(vSourceCells, 2), Cells(vSourceCells, 6)).Copy Range(Cells(vDestinationCells, 2), Cells(vDestinationCells, 5)).PasteSpecial xlPasteValues Next vSourceCells 'Copies expense section For vSourceCells = 47 To 77 Step 3 vDestinationCells = vSourceCells - 1 Range(Cells(vSourceCells, 2), Cells(vSourceCells, 6)).Copy Range(Cells(vDestinationCells, 2), Cells(vDestinationCells, 5)).PasteSpecial xlPasteValues Next vSourceCells Range("B9").Activate With Application .DisplayAlerts = True .ScreenUpdating = True End With
When the code runs, I can still see the cell pointer moving down the sheet.
I’ve turned off screenupdating in the past, and thought that the screen ‘froze’ until screenupdating was set to true.
Am I remembering wrong, or is screenupdating not working on my computer?
Thanks,