Morning all.
I am using a bit of code to scroll through a sheet. It run in a loop and to stop it, I just press escape.
How can I suppress the popup alert "Code execution has been interrupted"?
Application.DisplayAlerts = False does not work...
Here's the vba:
Thanks,
PuJo
I am using a bit of code to scroll through a sheet. It run in a loop and to stop it, I just press escape.
How can I suppress the popup alert "Code execution has been interrupted"?
Application.DisplayAlerts = False does not work...
Here's the vba:
Code:
Sub SlowScroll()
Application.DisplayAlerts = False
On Error Resume Next
Dim r As Long
Range("B8").Select
Do
DoEvents
Sleep 2000 'Pause 2 seconds - Scroll speed adjust
ActiveWindow.SmallScroll Down:=5
r = r + 1
If r = 50 Then Range("B8").Select: r = 0
Loop
On Error GoTo 0
End Sub
Thanks,
PuJo