Break Mode

F

FARAZ QURESHI

While executing the following code I am getting a message
"CANT EXECUTIVE CODE IN A BREAK MODE"

Sub FARAZCUT()
On Error GoTo ErrorHandler
Range("A4").End(xlDown).Select
ActiveCell.Offset(1, 0).Activate
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone,
SkipBlanks _
:=False, Transpose:=False
Exit Sub ' Exit to avoid handler.
ErrorHandler:
MsgBox "Copy Something First!"
End Sub

What might be the reason?
 
B

Bill Renaud

You mean:
"Can't execute code in break mode"

This is correct. While you have a breakpoint set and you are
single-stepping through that code, you cannot run another macro.

You need to finish single-stepping through the code where the breakpoint
is, then set a new breakpoint somewhere else and start debugging that code.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top